-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathindex.html
More file actions
88 lines (86 loc) · 3.9 KB
/
index.html
File metadata and controls
88 lines (86 loc) · 3.9 KB
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
81
82
83
84
85
86
87
88
<!DOCTYPE html>
<html lang="en" >
<head>
<meta charset="UTF-8">
<title>Kingdom</title>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/chessboard-js/1.0.0/chessboard-1.0.0.min.css">
<link rel="stylesheet" href="style.css">
<link rel="stylesheet" href="navbar/nav.css">
<link rel="apple-touch-icon" sizes="180x180" href="favicon_io/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="favicon_io/favicon-32x32.png">
<link rel="icon" type="image/png" sizes="16x16" href="favicon_io/favicon-16x16.png">
<link rel="manifest" href="favicon_io/site.webmanifest">
</head>
<body>
<div class="title">Two Kings on a Board</div><br>
<div style="text-align:center; font-size:20px; padding-bottom:5px">A simple game of Chess</div>
<nav>
<ul>
<li><a href="https://aceking007.github.io/">Home</a></li>
<li><a href="https://aceking007.github.io/projects/">Projects</a></li>
<li><a href="instructions.html">How to play</a></li>
<li class='active'><a href="">Play</a></li>
</ul>
</nav><br>
<main style="margin: auto">
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.5.1/jquery.min.js" integrity="sha512-bLT0Qm9VnAYZDflyKcBaQ2gg0hSYNQrJ8RilYldYQ1FxQYoCLtUjuuRuZo+fjqhx/qtq/1itJ0C2ejDxltZVFg==" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/chess.js/0.11.0/chess.min.js" integrity="sha512-fQm9eU+Lz0kPDBNJyVJUrMDEOfao7Y+HGcF3HOi/bTl3nL0OsV4vr95x4JjETA1mUng0CPztfPXuIjBoDBUW1w==" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/chessboard-js/1.0.0/chessboard-1.0.0.min.js" integrity="sha512-WfASs5HtTgTL/eZsLaOftSN9wMQl7WZGlU5UiKx/yxTViMfGh9whWRwKAC27qH8VtZJqSMqDdbq2uUb1tY3jvQ==" crossorigin="anonymous"></script>
<div id="myBoard" style="width: 45%; margin: auto"></div>
<div id="statusBar">
<label><b>Status:</b></label>
<div id="status"></div>
<!-- <label><b>FEN:</b></label>
<div id="fen"></div> -->
<label><b>Moves:</b></label>
<div id="pgn"></div>
<br>
</div>
<div id="buttons">
<button id="undoBtn">Undo Last Move</button>
<table class='buttons'>
<tr>
<td><button id="resetBtn" class='btn'>Reset Board
<span>Resets everything</span></button>
<td><button id='playLevel0' class='btn'>Play against Level 0 AI
<span>Play against an AI that plays pseudorandom moves</span></button>
<tr>
<td><button id="flipOrientationBtn" class='btn'>Flip Board
<span>Flip the orientation of the board</span></button>
<td><button id='playLevel1' class='btn'>Play against Level 1 AI
<span>Play against an AI that is hell-bent on capturing your pieces</span></button>
<tr>
<td><button id="playRandomBtn" class='btn'>Simulate Random Game
<span>Simulate a game between two Level 0 AIs</span></button>
<td><button id='playLevel2' class='btn'>Play against Level 2 AI
<span>Play against an AI that understands basic chess tactics</span></button>
<tr>
<td><button id='showPositionBtn' class='btn'>Show Position in Console
<span>Check the console for more info</span></button>
<td><button id='playLevel3' class='btn'>Play against Level 3 AI
<span>Play against a faster AI that understands basic chess tactics</span></button>
<tr>
<br>
</div>
<div class='info'>
<b>Performance index for AI</b><br>
Search depth (For AI Level 2 and above):
<select id='search-depth'>
<option value='1'>1</option>
<option value='2'>2</option>
<option value='3'>3</option>
<option value='4'>4</option>
<option value='5'>5</option>
</select>
<br>
<span>Positions evaluated: <span id="position-count"></span></span>
<br>
<span>Time: <span id="time"></span></span>
<br>
<span>Positions/sec: <span id="positions-per-s"></span> </span>
<br>
</div>
</main>
<script src="main.js"></script>
</body>
</html>