Skip to content

tarolandia/peg-solitaire

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 

Repository files navigation

#Peg Solitaire Game

How to build a board

HTML

<div id="build-here"></div>

Javascript

    $("#build-here").pegBoard();

Reset a board

    $("#build-here").pegBoard("reset");

Destroy a board

    $("#build-here").pegBoard("destroy");

Settings

	$("#build-here").pegBoard({ <br>
		'gameCSS': 'game.css', // styles<br>
		'pegImg': 'peg.png', //peg image<br>
		'onWin': function() { alert("You win!!!"); }, // event for winner board<br>
		'onNoMoves': function() { alert("No moves"); } // event for loser board<br>
	});

Releases

No releases published

Packages

No packages published