forked from sinkstyt/Dice-of-Pigs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
80 lines (80 loc) · 3.7 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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
<!DOCTYPE html>
<html>
<head>
<title>Pig Dice</title>
<link rel="stylesheet" href="css/bootstrap.css">
<link rel="stylesheet" href="css/styles.css">
<link href="https://fonts.googleapis.com/css2?family=Modak&family=Teko:wght@300&family=Wire+One&display=swap" rel="stylesheet">
<script src="js/jquery-3.5.1.js"></script>
<script src="js/scripts.js"></script>
</head>
<body>
<div class="container">
<div style="background: transparent;" class="jumbotron">
<h1>PIG DICE</h1>
<ul class="instructions" id="instructions"><h2>How to play:</h2>
<li>Object of the game: to reach or exceed 100 points</li>
<li>Play begins with a roll of a die</li>
<li>Anytime a 1 is rolled, the current turn ends and no points are added to the current player's total score</li>
<li>On roll of anything besides 1, player elects to "hold" or roll again.</li>
<li>On "roll again" all the previous rolls are summed as a turn's score</li>
<li>"Hold" adds the current turn's sum to the player's total score</li>
</ul>
</div>
<div class="name-entry">
<h2>Please Enter Player Names:</h2>
<form class="form-check">
<div class="row">
<div class="col-md-6 col-xs-12">
<label class="form-check-inline" for="player1-name">
<input class="form-check-inline" type="text" id="player1-name" placeholder="Charlie">
</div>
<div class="col-md-6 col-xs-12">
<label class="form-check-inline" for="player2-name">
<input class="form-check-inline" type="text" id="player2-name" placeholder="Brandy">
</div>
</div>
<div class="buttons">
<button type="submit" class="btn btn-primary">Let's Play</button>
</div>
</form>
</div>
<div class="row">
<div class="card col-md-4 text-center" id="player1-card">
<div class="card-body">
<h3 class="card-title" id="player1-name"></h3>
<div class="buttons">
<button type="button" id="Charlie-roll" class="btn btn-primary">Roll!</button>
<button type="button" id="Charlie-hold" class="btn btn-dark">Hold!</button>
</div>
<ul class="list group list-group-flush">
<li class="list-group-item">Total Score: <span id="player1-total-score"></span></li>
<li class="list-group-item">Turn Score: <span id="player1-turn-score"></span></li>
<li class="list-group-item">This turn's rolls:</li>
<ul class="turn-rolls list-inline">
</ul>
<li class="list-group-item">Turn: <span id="player1-turn"></span></li>
</ul>
</div>
</div>
<div class="card col-md-4 text-center" id="player2-card">
<div class="card-body">
<h3 class="card-title" id="player2-name"></h3>
<div class="buttons">
<button type="button" id="Brandy-roll" class="btn btn-primary">Roll!</button>
<button type="button" id="Brandy-hold" class="btn btn-dark">Hold!</button>
</div>
<ul class="list group list-group-flush">
<li class="list-group-item">Total Score: <span id="player2-total-score"></span></li>
<li class="list-group-item">Turn Score: <span id="player2-turn-score"></span></li>
<li class="list-group-item">This turn's rolls:</li>
<ul class="turn-rolls list-inline">
</ul>
<li class="list-group-item">Turn: <span id="player2-turn"></span></li>
</ul>
</div>
</div>
</div>
</div>
</body>
</html>