-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
220 lines (213 loc) · 7.92 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
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
<html>
<head>
<!-- Google tag (gtag.js) -->
<script async src="https://www.googletagmanager.com/gtag/js?id=G-5YQ35KLDYG"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'G-5YQ35KLDYG');
</script>
<title>Noir</title>
<link rel="icon" href="./img/bogart.ico">
<link rel="stylesheet" href="game.css">
</head>
<body style="background-color:#eec49b;">
<div id="start-screen">
<center>
<img src="./img/noir-cover.png" height="40%"> <br>
<span class="typewriter-title">Noir.</span> <br>
<br>
<button onClick="showCharacterBuilderWindow();" class="game-button">New Game (Create Character)</button>
<br> <br>
<button onClick="startGame(PLAYER_SAM_SPADE, undefined);" class="game-button">New Game (Sam Spade)</button>
<br> <br>
<button onClick="startGame(PLAYER_CARRIE_CASHIN, undefined);" class="game-button">New Game (Carrie Cashin)</button>
<br> <br>
<button onClick="showGameLoaderWindow();" class="game-button">Load Previous Game</button>
<br> <br>
<span>Version 0.1.12</span> <br>
<span>09 Apr 2023</span>
</center>
</div>
<div id="main-screen" hidden="true">
<table>
<tr>
<!-- image area -->
<td valign="top" width="20%" rowspan="2">
<div id="images" class="image-parent"></div>
</td>
<!-- story area -->
<td valign="top" width="60%">
<div id="story"></div>
</td>
<!-- character area -->
<td valign="top" width="20%">
<center>
<div id="character-image"></div>
<div id="healthbar"></div>
<span id="character-name"></span>
<br>
<table>
<tr>
<td align="right" style="padding: 0.2cm;"><button onClick="showCharacterWindow();" class="game-button">Character</button></td>
<td align="left" style="padding: 0.2cm;"><button onClick="showInventoryWindow();" class="game-button">Inventory</button></td>
</tr>
<tr>
<td align="right" style="padding: 0.2cm;"><button onClick="showNotebookWindow();" class="game-button">Notebook</button></td>
<td align="left" style="padding: 0.2cm;"><button onClick="showRecordsWindow();" class="game-button">Case File</button></td>
</tr>
<tr>
<td align="center" colspan="2" style="padding: 0.2cm;"><button onClick='downloadTextFile("savegame.txt", getSavegameFile());' class="game-button">Save Game</button></td>
</tr>
<tr>
<td align="center" colspan="2" style="padding: 0.2cm;"><img src="./img/radio.png" width="40%" onclick="showSoundControlsWindow();"></td>
</tr>
</table>
</center>
</td>
</tr>
<tr>
<!-- options area -->
<td valign="top" width="60%">
<div id="options"></div>
</td>
<!-- console area -->
<td valign="top" width="20%">
<div id="console" class="console"></div>
</td>
</tr>
</table>
</div>
<!-- pop-up windows-->
<div class="container-popup" id="game-loader" hidden="true">
<div class="popup" style="height: 40%;">
<center>
<b><span>Load Game</span></b> <br>
<form id="upload">
<label for="file" class="game-button">Upload a previously saved game:</label> <br>
<input type="file" class="game-button" id="file" accept=".txt"> <br>
<br>
<button class="game-button">Load Previous Game</button> <button onClick="hideGameLoaderWindow();" class="game-button">Cancel</button>
</form>
</center>
</div>
</div>
<div class="container-popup" id="character-builder" hidden="true">
<div class="popup" style="height: 80%;">
<center>
<b><span>New Character</span></b>
<br>
<table width="80%">
<td>
<span id="character-builder-gender">
</span>
</td>
<td>
<center>
<div id="character-builder-image"></div> <br>
</center>
</td>
<td style='text-align: right;'>
<span>First Name:</span><br>
<span>Last Name:</span>
</td>
<td>
<input type="text" id="character-builder-firstname" name="character-builder-firstname" required maxlength="12" size="14" class="game-button"> <br>
<input type="text" id="character-builder-lastname" name="character-builder-lastname" required maxlength="12" size="14" class="game-button">
</td>
</table>
<span>--- Abilities ---</span>
<table id="character-builder-abilities" width="80%">
</table>
<button onClick="createCharacter();" class="game-button">Start Game</button>
<button onClick="hideCharacterBuilderWindow();" class="game-button">Cancel</button>
</center>
</div>
</div>
<div class="container-popup" id="character-stats" hidden="true">
<div class="popup" style="height: 80%;">
<center>
<b><span>Character Sheet</span></b>
<br>
<span>Abilities</span>
<table id="character-abilities" width="50%">
</table>
<button onClick="hideCharacterWindow();" class="game-button">Close</button>
</center>
</div>
</div>
<div class="container-popup" id="notebook" hidden="true">
<div class="popup" style="background: #ffffff url('./img/journal_page_bg.jpg'); padding: 10px; height: 80%;">
<center>
<b><span class="journal">Notes</span></b>
<br>
</center>
<div id="notebook-entries"></div>
<center>
<br>
<button onClick="hideNotebookWindow();" class="game-button">Close</button>
</center>
</div>
</div>
<div class="container-popup" id="records" hidden="true">
<div class="popup" style="background: #ffffff url('./img/papertexture.jpg'); overflow-y: scroll; padding: 10px; height: 80%;">
<center>
<b><span class="typewriter">Case File</span></b>
<br>
</center>
<div id="records-body"></div>
<center>
<br>
<button onClick="hideRecordsWindow();" class="game-button">Close</button>
</center>
</div>
</div>
<div class="container-popup" id="inventory" hidden="true">
<div class="popup" style="background: #ffffff url('./img/suitcase.png'); padding: 10px; background-size: contain; background-repeat: no-repeat; aspect-ratio: 1217/883;">
<div align="right"><button onClick="hideInventoryWindow();" class="game-button"> X </button></div>
<div id="empty-space" width="100%" style="height: 20%;"> </div>
<div>
<center>
<table width="80%" id="inventory-table">
</table>
</center>
</div>
</div>
</div>
<div class="container-popup" id="map" hidden="true">
<div class="popup" style="background: #ffffff url('./img/triste-le-roy-map.png'); padding: 10px; background-size: contain; background-repeat: no-repeat; aspect-ratio: 1217/883;">
<div align="right"><button onClick="hideMapWindow();" class="game-button"> X </button></div>
<div id="empty-space" width="100%" style="height: 20%;"> </div>
<div>
<center>
<table width="80%" id="map-table">
</table>
</center>
</div>
</div>
</div>
<div class="container-popup" id="show-object" hidden="true" style="width: 40%; background-color: transparent; margin: auto;">
<div>
<div align="right"><button onClick="hideObject();" class="game-button"> X </button></div>
<center>
<img id="object-image" style="max-width: 100%"/>
</center>
</div>
</div>
<div class="container-popup" id="sound-controls" hidden="true">
<div class="popup" style="height: 40%;">
<div align="right"><button onClick="hideSoundControlsWindow();" class="game-button"> X </button></div>
<center>
<b><span>Volume Control</span></b> <br>
<table>
<tr><td align="center"><button class='game-button' onClick='decreaseMusicVolume();'>-</button> <span>Music</span> <button class='game-button' onClick='increaseMusicVolume();'>+</button></td></tr>
<tr><td align="center"><button class='game-button' onClick='decreaseSoundfxVolume();'>-</button> <span>SoundFx</span> <button class='game-button' onClick='increaseSoundfxVolume();'>+</button></td></tr>
</table>
</center>
</div>
</div>
<script src="js/game.js"></script>
</body>
</html>