-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
59 lines (59 loc) · 2.54 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Mancala</title>
<link rel="stylesheet" href="styles.css" />
</head>
<body>
<h1>Mancala</h1>
<div class="player-turn">
Player <span id="current-player">1</span>'s turn
</div>
<p>Player 2</p>
<div class="board">
<div id="p2-score">Player 2:</div>
<div class="store" id="store-player2">Store</div>
<div class="rows">
<div id="row1">
<div class="pit" id="pit12">Pit</div>
<div class="pit" id="pit11">Pit</div>
<div class="pit" id="pit10">Pit</div>
<div class="pit" id="pit9">Pit</div>
<div class="pit" id="pit8">Pit</div>
<div class="pit" id="pit7">Pit</div>
</div>
<div id="row2">
<div class="pit" id="pit1">Pit</div>
<div class="pit" id="pit2">Pit</div>
<div class="pit" id="pit3">Pit</div>
<div class="pit" id="pit4">Pit</div>
<div class="pit" id="pit5">Pit</div>
<div class="pit" id="pit6">Pit</div>
</div>
</div>
<div class="store" id="store-player1">Store</div>
<div id="p1-score">Player 1:</div>
</div>
<p>Player 1</p>
<div>
<button id="reset-button">Reset Game</button>
</div>
<div class="rules">
<p id="game-rules">Game Rules:</p>
<ol>
<li>The game begins with one player picking up all of the pieces in any one of the pockets on his/her side.</li>
<li>Moving counter-clockwise, the player deposits one of the stones in each pocket until the stones run out.</li>
<li> If you run into your own Mancala (store), deposit one piece in it. If you run into your opponent's Mancala, skip it and continue moving to the next pocket.</li>
<li> If the last piece you drop is in your own Mancala, you take another turn.</li>
<li> If the last piece you drop is in an empty pocket on your side, you capture that piece and any pieces in the pocket directly opposite.</li>
<li> Always place all captured pieces in your Mancala (store).</li>
<li> The game ends when all six pockets on one side of the Mancala board are empty.</li>
<li> The player who still has pieces on his/her side of the board when the game ends captures all of those pieces.</li>
<li> Count all the pieces in each Mancala. The winner is the player with the most pieces.</li>
</ol>
</div>
<script src="app.js"></script>
</body>
</html>