-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
141 lines (141 loc) · 8.09 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
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="description" content="The world's best Letterpress AI">
<meta name="keywords" content="Letterpress,cheat,AI,game,helper,Jemmin,Chang">
<meta name="author" content="Jemmin Chang">
<title>Lettercrush | Jemmin Chang</title>
<link type="text/css" rel="stylesheet" href="lettercrush-style.css">
<!-- Get jQuery from Google -->
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
<script src="run-lettercrush.js"></script>
</head>
<body>
<div id="loading" class="page">
<h1><!--For displaying all sorts of loading messages--></h1>
</div>
<div id="title" class="page">
<div id="nojs">
<h2>This application requires JavaScript to run. Please enable JavaScript and reload the page. (Click <a href="http://www.enable-javascript.com/">here</a> for help enabling JavaScript.)</h2>
</div>
<div id="no-storage">
<h2>Oops! Your browser is outdated. This application requires HTML5 Web Storage support to run; please try opening this page in <a href="http://www.google.com/chrome">Google Chrome</a> (recommended), Safari, Firefox, Opera, or Internet Explorer version 8 or higher.</h2>
</div>
<div id="yes-storage">
<h3>Important: this application was designed for and runs best on <a href="http://www.google.com/chrome">Google Chrome</a>. It is <strong>strongly recommended</strong> that you run it on the latest version of Chrome.</h3>
<h1>Lettercrush</h1>
<h2>The world's smartest AI for <a href="http://itunes.apple.com/us/app/letterpress-word-game/id526619424" target="_blank">Letterpress</a></h2>
<form id="access-form" action="index.html">
<label>Access code:</label>
<input type="text" name="access-code" autofocus>
<button type="submit">Go</button>
</form>
<h4 id="denied">Access Denied</h4>
</div>
<h4>© Jemmin Chang 2014</h4>
</div><!-- end #title page-->
<div id="games" class="page">
<h1>Select a game:</h1>
<div class="left-side">
<table id="preview-board" class="letter-board">
<tbody><!-- Letterpress board - fill with JS-->
<tr><td></td><td></td><td></td><td></td><td></td></tr>
<tr><td></td><td></td><td></td><td></td><td></td></tr>
<tr><td></td><td></td><td></td><td></td><td></td></tr>
<tr><td></td><td></td><td></td><td></td><td></td></tr>
<tr><td></td><td></td><td></td><td></td><td></td></tr>
</tbody>
</table>
<h2 class="score"><!--score goes here--></h2>
</div>
<form id="game-select-form" action="index.html">
<div><!-- for parallel structure with JS-added elements -->
<input type="radio" name="game-selected" value="new-game"> New Game<br>
<label>Name:</label>
<input id="new-name" type="text" maxlength="20"><br>
<span id="new-name-error"></span>
</div>
<button type="submit">Open</button><br>
</form>
</div><!-- end #games page-->
<div id="play" class="page">
<button type="button" id="back-to-games" class="return-button">Back to games list</button>
<h1 id="turn-indicator"><!--says whose turn it is--></h1>
<div class="left-side">
<table id="game-board" class="letter-board">
<tbody><!-- Letterpress board - fill with JS-->
<tr><td></td><td></td><td></td><td></td><td></td></tr>
<tr><td></td><td></td><td></td><td></td><td></td></tr>
<tr><td></td><td></td><td></td><td></td><td></td></tr>
<tr><td></td><td></td><td></td><td></td><td></td></tr>
<tr><td></td><td></td><td></td><td></td><td></td></tr>
</tbody>
</table>
<h2 class="score"><!-- current score goes here --></h2>
</div>
<div id="gen-moves" class="right-side play-panel">
<h3>Generate best moves:</h3>
<form id="gen-form" action="index.html">
<label>Max time:</label>
<input type="number" name="time-limit" min="1" max="15" value="5">
<br>
<label>Max depth:</label>
<input type="number" name="depth-limit" min="1" max="10">
<br>
<label>Moves to generate:</label>
<input type="number" name="list-len" min="1" max="20" value="5">
<br>
<button type="submit">Go</button>
</form>
</div>
<div id="thinking" class="right-side play-panel">
<h3>Thinking...</h3>
</div>
<div id="choose-move" class="right-side play-panel">
<form id="choose-form" action="index.html">
<input type="radio" name="move-selected" value="construct"> Custom move
<br>
<button type="submit">Play</button>
</form>
</div>
<div id="construct-move" class="right-side play-panel">
<span id="word-construct"><!--word being constructed goes here--></span>
<form id="construct-form" action="index.html">
<button type="button" id="construct-backspace">BS</button>
<button type="button" id="construct-clear">Clear</button>
<br>
<button type="submit">Play</button>
</form>
</div>
</div><!-- end #play page-->
<div id="new-game" class="page">
<button type="button" id="cancel-new" class="return-button">Cancel</button>
<h1>Create a new Game:</h1>
<form id="new-form" action="index.html">
<div class="left-side">
<table id="new-board" class="letter-board">
<tbody><!-- editable Letterpress board -->
<tr><td class="white"><input type="text" maxlength="1" size="1"></td><td class="white"><input type="text" maxlength="1" size="1"></td><td class="white"><input type="text" maxlength="1" size="1"></td><td class="white"><input type="text" maxlength="1" size="1"></td><td class="white"><input type="text" maxlength="1" size="1"></td></tr>
<tr><td class="white"><input type="text" maxlength="1" size="1"></td><td class="white"><input type="text" maxlength="1" size="1"></td><td class="white"><input type="text" maxlength="1" size="1"></td><td class="white"><input type="text" maxlength="1" size="1"></td><td class="white"><input type="text" maxlength="1" size="1"></td></tr>
<tr><td class="white"><input type="text" maxlength="1" size="1"></td><td class="white"><input type="text" maxlength="1" size="1"></td><td class="white"><input type="text" maxlength="1" size="1"></td><td class="white"><input type="text" maxlength="1" size="1"></td><td class="white"><input type="text" maxlength="1" size="1"></td></tr>
<tr><td class="white"><input type="text" maxlength="1" size="1"></td><td class="white"><input type="text" maxlength="1" size="1"></td><td class="white"><input type="text" maxlength="1" size="1"></td><td class="white"><input type="text" maxlength="1" size="1"></td><td class="white"><input type="text" maxlength="1" size="1"></td></tr>
<tr><td class="white"><input type="text" maxlength="1" size="1"></td><td class="white"><input type="text" maxlength="1" size="1"></td><td class="white"><input type="text" maxlength="1" size="1"></td><td class="white"><input type="text" maxlength="1" size="1"></td><td class="white"><input type="text" maxlength="1" size="1"></td></tr>
</tbody>
</table>
<span id="new-incomplete">Please fill in the entire board.</span>
<h4>Click outside the letter to change the tile's color. Just select blue or red: we'll automatically figure out which ones are locked for you.</h4>
</div>
<div class="right-side">
<input type="radio" name="whose-turn" value="mine" checked> My turn
<br>
<input type="radio" name="whose-turn" value="opp"> Opponent's turn
<br>
<textarea name="played-words" rows="5" cols="20" placeholder="List the words that have already been played here, each on a separate line."></textarea>
<br>
<button type="submit">Start</button>
</div>
</form>
</div><!-- end #new-game page-->
<body>
</html>