forked from jotitan/monopoly
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmonopoly-template.html
342 lines (314 loc) · 15.4 KB
/
monopoly-template.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
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>Monopoly FULL JS</title>
<link type="text/css" href="css/ui/jquery-ui.min.css" rel="stylesheet" />
<link type="text/css" href="css/ui/jquery-ui.structure.min.css" rel="stylesheet" />
<link type="text/css" href="css/ui/jquery-ui.theme.min.css" rel="stylesheet" />
<link rel="shortcut icon" type="image/x-icon" href="favicon.ico" />
<script type="text/javascript" src="lib/jquery-1.11.0.min.js"></script>
<script type="text/javascript" src="lib/jquery-ui.1.12.min.js"></script>
<script type="text/javascript" src="lib/jquery.mousewheel.js"></script>
<script type="text/javascript" src="lib/jquery.arctext.js"></script>
<!--(if target dev)><!-->
<script type="text/javascript" src="js/sauvegarde.js"></script>
<script type="text/javascript" src="js/utils.js"></script>
<script type="text/javascript" src="js/gestion_constructions.js"></script>
<script type="text/javascript" src="js/gestion_terrains.js"></script>
<script type="text/javascript" src="js/enchere.js"></script>
<script type="text/javascript" src="js/ui/graphics.js"></script>
<script type="text/javascript" src="js/ui/square_graphics.js"></script>
<script type="text/javascript" src="js/ui/circle_graphics.js"></script>
<script type="text/javascript" src="js/display/message.js"></script>
<script type="text/javascript" src="js/entity/comportement.js"></script>
<script type="text/javascript" src="js/entity/strategie.js"></script>
<script type="text/javascript" src="js/entity/pion.js"></script>
<script type="text/javascript" src="js/entity/joueur.js"></script>
<script type="text/javascript" src="js/entity/network/local_joueur.js"></script>
<script type="text/javascript" src="js/entity/network/remote_manager.js"></script>
<script type="text/javascript" src="js/entity/joueur_robot.js"></script>
<script type="text/javascript" src="js/gestion_joueurs.js"></script>
<script type="text/javascript" src="js/entity/cartes_action.js"></script>
<script type="text/javascript" src="js/display/displayers.js"></script>
<script type="text/javascript" src="js/display/case_jeu.js"></script>
<script type="text/javascript" src="js/entity/dices.js"></script>
<script type="text/javascript" src="js/monopoly.js"></script>
<!--<!(endif)-->
<!--(if target prod)><!-->
<!--script type="text/javascript" src="monopoly-min.js"></script-->
<!--<!(endif)-->
<style></style>
<link rel="stylesheet" type="text/css" href="css/style.css"/>
</head>
<body>
<table><tr>
<td style="vertical-align:top">
<div id="informations-left" class="panneau_joueur"></div>
</td>
<td>
<div style="width:810px;height:810px;position:relative" id="plateau" class="graphic_element">
<canvas id="canvas" width="810" height="810" style="top:0px;left:0px;position:absolute"></canvas>
<canvas id="canvas_rt" width="810" height="810" style="top:0px;left:0px;position:absolute"></canvas>
<div>
<img src="img/reload_dice.png" style="display:none;" id="idReloadDice" title="Relancez" class="graphic_element"/>
<div id="idActions">
<button title="Lancez les dés" id="idLancerDes" class="action-joueur" disabled="disabled">
<img src="img/dices.png"/>
</button>
<button title="Achat maisons" class="action-joueur action-normal" onclick="GestionTerrains.open()" disabled="disabled">
<img src="img/house2.png"/>
</button>
<button title="Echange terrains" id="idEchangeTerrains" class="action-normal action-joueur" onclick="EchangeDisplayer.open(GestionJoueur.getJoueurCourant())" disabled="disabled">
<img src="img/swap.png"/>
</button>
<button title="Terrains libres" class="action-joueur" onclick="$('#idTerrainsLibres').dialog('open');" disabled="disabled">
<img src="img/list.png"/>
</button>
</div>
<div style="position:absolute;top:300px;left:150px;border:solid 1px black;border-radius:10px;width:175px;padding:5px" id="idMontantParc">
Parc Gratuit : Frs <span></span>
</div>
<div id="idTitle" class="title" style="position: absolute; left: 400px; top: 180px;">
<h1 id="idSavePanel" title="Cliquez pour sauvegarder">MONOPOLY</h1>
<h2 id="idSubTitle"></h2>
</div>
<div class="info_box graphic_element" id="idInfoBox">
<div></div><div></div><div></div><div></div>
</div>
</div>
</div>
</td>
<td style="vertical-align:top">
<!--(if target dev)><!-->
<div id="idDebug" style="display:none">
case : <input type="text" size="3" id="nb"/><input type="button" onclick="GestionJoueur.getJoueurCourant().joueDes(parseInt($('#nb').val()))" value="click"/><br/>
Goto : <input type="text" size="3" id="ide"/><input type="text" size="3" id="idp"/><input type="button" onclick="GestionJoueur.getJoueurCourant().pion.goto($('#ide').val(),$('#idp').val(),doActions)" value="goto"/><br/>
</div>
<!--<!(endif)-->
<div id="informations" class="panneau_joueur"></div>
</td>
</tr></table>
<div id="informations-bottom" class="panneau_joueur" style="width:100%"></div>
<div id="fiche" style="background-color:white;font-size:12px">
<table>
<tr><td></td><td>€</td></tr>
<tr><td>ACHAT</td><td id="achat" name="achat"></td></tr>
<tr><td>LOYER terrain nu</td><td class="loyer0"></td></tr>
<tr class="maison"><td> - 1 maison</td><td class="loyer1" name="loyer1"></td></tr>
<tr class="maison"><td> - 2 maisons</td><td class="loyer2" name="loyer2"></td></tr>
<tr class="maison"><td> - 3 maisons</td><td class="loyer3" name="loyer3"></td></tr>
<tr class="maison"><td> - 4 maisons</td><td class="loyer4" name="loyer4"></td></tr>
<tr class="maison"><td> - Hotel</td><td class="loyer5" name="loyer5"></td></tr>
</table>
<hr/>
<div class="infos-group">
Loyer double si <span style="font-weight:bold">TOUS</span> les terrains du groupe de Couleur.
</div>
<hr/>
<div>
Prix des Maisons F <span id="prixMaison" name="prixMaison"></span><br/>
Prix d'un Hôtel F <span id="prixHotel" name="prixMaison"></span><br/>
</div>
Valeur hypotécaire : Frs <span id="hypotheque" name="montantHypotheque"></span>
</div>
<div id="ficheJunior" style="background-color:white;font-size:12px">
<table>
<tr><td></td><td>€</td></tr>
<tr><td>ACHAT</td><td id="acht" name="achat"></td></tr>
<tr><td>LOYER</td><td class="loyer0"></td></tr>
</table>
<hr/>
<div class="infos-group">
Loyer double si <span style="font-weight:bold">TOUS</span> les terrains du groupe de Couleur.
</div>
<hr/>
</div>
<div id="ficheCompagnie" style="background-color:white">
<br/>
Si l'on possède UNE carte de compagnie de Service Public, le loyer est 400 fois le montant indiqué par les dés.<br/><br/>
Si l'on possède les DEUX cartes de compagnies de Service Public, le loyer est MILLE fois le montant indiqué par les dés.<br/><br/>
Valeur hypotécaire : Frs 7.500
</div>
<div id="achatMaisons" style="background-color:white;"></div>
<div id="message" style="display:none;background-color:white"></div>
<div style="display:none" id="housesPanel">
<div style="width:50%;height:calc(100% - 45px);background-color:white;float:left">
<div class="title-dialog">Hypotheque</div>
<fieldset id="idTerrainsHypotheques" style="border:solid 1px darkgrey;margin-top:10px;">
<legend>Terrains hypothéqués</legend>
<div>
</div>
</fieldset>
<fieldset id="idTerrains" style="border:solid 1px darkgrey;margin-top:10px;">
<legend>Terrains hypothécables</legend>
<select></select>
<button id="idHypothequeAction">Hypothéquer</button>
<div id="toHypotheque"></div>
</fieldset>
</div>
<div style="width:50%;height:calc(100% - 45px);background-color:white;float:right">
<div class="title-dialog">Constructions</div>
<div id="idTerrainsConstructibles" class="constructions" style="padding-left: 10px"></div>
<hr style="margin-right:10px;width:150px;float:right;"/>
<div style="clear:both"></div>
<div style="margin-right:40px;float:right" id="coutAchats">
<img src="img/maison.png" style="width:15px;"/> x <span name="nbMaison">0</span>
<img src="img/hotel.png" style="width:15px;"/> x <span name="nbHotel">0</span>
<span name="cout" style="margin-left: 10px"></span> <span class="currency-value"></span>
</div>
<div style="clear:both"></div>
<div style="margin-right:40px;float:right" id="resteConstructions">
Reste <img src="img/maison.png" style="width:15px;"/> x <span name="nbMaison">0</span>
<img src="img/hotel.png" style="width:15px;"/> x <span name="nbHotel">0</span>
</div>
</div>
<div id="idTest" style="clear:both;width:100%;height:40px">
<table style="height:100%;width:100%;border:0;border-collapse: collapse"><tr>
<td style="width:37%;height:100%;border-top:solid 1px black;"></td>
<td style="width:26%;border:solid 1px black;padding:5px;background-color:white">
Resultat : <span id="idCoutTotal"></span><br/>
Porte-monnaie : <span id="idArgentRestant"></span>
</td>
<td style="width:37%;border-top:solid 1px black;"></td>
</tr></table>
</div>
</div>
<div id="idTerrainsLibres"></div>
<div style="display:none" id="infoJoueur">
<div style="font-size:12px">
<span class="info-label">Type</span> : <span name="type"></span><br/>
<span class="info-label"><img src="img/strategy.png" style="width:18px;"/></span> : <span name="strategie"></span><br/>
<span class="info-label"><img src="img/behaviour.png" style="width:18px;"/></span> : <span name="comportement"></span><br/>
<span class="info-label"><img src="img/money.png" style="width:18px;"/></span> : <span name="argent"></span><br/>
<span class="info-label"><img src="img/money.png" style="width:18px;"/><img src="img/money.png" style="width:18px;"/></span> : <span name="argentDispoHypo"></span><br/>
<span class="info-label"><img src="img/money.png" style="width:18px;"/><img src="img/money.png" style="width:18px;"/><img src="img/money.png" style="width:18px;"/></span> : <span name="argentDispo"></span><br/>
<span class="info-label"><img src="img/maison.png" style="width:15px;"/></span> : <span name="maison"></span><br/>
<span class="info-label"><img src="img/hotel.png" style="width:15px;"/></span> : <span name="hotel"></span><br/>
<span class="info-label"><img src="img/jail.jpg" style="width:18px;"/></span> : <span name="prison"></span> fois<br/>
<span class="info-label"><img src="img/tour.png" style="width:18px;"/></span> : <span name="tour"></span> tour(s)
</div>
</div>
<div style="display:none;background-color:#CEE6D0" id="idPanelCreatePartie">
<div id="idCreationGame">
<ul>
<li><a href="#create">Créer partie</a></li>
<li><a href="#join">Rejoindre</a></li>
</ul>
<div id="create">
Joueur : <input type="text" id="idNomJoueur" name="joueur" placeholder="Nom"/><br/>
<fieldset id="idGameType">
<legend style="font-weight:bold">Plateau</legend>
<div style="display:inline-block;width:75px;">Plateau</div>
<select id="idSelectPlateau"></select><br/>
<div style="display:inline-block;width:75px;">Type</div>
<input type="radio" name="typeGame" value="classic" id="idClassiqueGame" checked/><label for="idClassiqueGame">Classique</label>
<input type="radio" name="typeGame" value="quick" id="idQuickGame"/><label for="idQuickGame">Rapide</label><br/>
<div style="display:inline-block;width:75px;">Réseau</div>
<input type="radio" name="networkGame" value="false" id="idLocalTypeGame" checked/><label for="idLocalTypeGame">Non (local)</label>
<input type="radio" name="networkGame" value="true" id="idNetworkTypeGame"/><label for="idNetworkTypeGame">Oui</label>
</fieldset>
<fieldset>
<legend style="font-weight:bold">Créer une partie</legend>
<fieldset id="idPartie"><legend>Joueurs</legend>
<div>
<div style="display:inline-block;width:75px;">Total</div>
<div id="sliderJoueur" style="width:180px;display:inline-block">
<div id="valueSliderJoueur" class="ui-slider-handle"></div>
</div>
</div>
<div>
<div style="display:inline-block;width:75px;">Robots</div>
<div id="sliderRobot" style="width:180px;display:inline-block">
<div id="valueSliderRobot" class="ui-slider-handle"></div>
</div>
</div>
<!--Rapidité des robots :
<select name="waitTimeIA">
<option value="100" selected>0s</option>
<option value="1000">1s</option>
<option value="1500">1.5s</option>
<option value="2000">2s</option>
<option value="4000">4s</option>
</select>
-->
</fieldset>
<fieldset id="idVariantes">
<legend>Variantes</legend>
<input type="checkbox" name="parcGratuit" id="idOptParcGratuit"/> <label for="idOptParcGratuit">Toucher le parc gratuit</label><br/>
<input type="checkbox" name="caseDepart" id="idOptCaseDepart"/> <label for="idOptCaseDepart">Toucher double sur la case depart</label><br/>
<input type="checkbox" name="enchereAchat" id="idOptCaseEnchere"/> <label for="idOptCaseEnchere">Banque met terrain aux enchères</label><br/>
<input type="checkbox" name="echangeApresVente" id="idOptCaseEchange"/> <label for="idOptCaseEchange">Echange quand terrains vendus</label><br/>
<!--input type="checkbox" name="tourAchat" id="idOptTourAchat"/> <label for="idOptTourAchat">Un tour avant achat (not yet)</label-->
<hr/>
<input type="checkbox" name="quickMove" id="idQuickMove"/> <label for="idQuickMove">Jeu rapide</label><br/>
</fieldset>
</fieldset>
<fieldset>
<legend style="font-weight:bold">Charger une sauvegarde</legend>
<select id="idSauvegardes">
<option value="">---</option>
</select>
<button id="idDeleteSauvegarde">Supprimer</button>
<button id="idLoadSauvegarde">Charger</button>
</fieldset>
</div>
<div id="join">
Joueur : <input type="text" id="idRemoteNomJoueur" name="joueur" placeholder="Nom"/><br/>
Partie : <input type="text" id="idRemoteGame" placeholder="ID Partie"/><br/>
</div>
</div>
</div>
<div id="idPanelEchange">
Joueur :
<select id="idSelectJoueurs">
<option value="">---</option>
</select>
<fieldset>
<legend>Liste de ses terrains</legend>
<select id="idListTerrainsAdversaire"><option value="">---</option></select>
</fieldset>
<fieldset>
<legend>Proposition</legend>
<div id="idListTerrainsJoueur"></div>
Argent : <input type="text" id="idArgentProposition"/>
</fieldset>
</div>
<div id="idCommunicationEchange">
<div class="proposition"></div>
<div class="communications"></div>
</div>
<div id="idEncherePanel">
<div><span class="proprietaire"></span> met en Vente <span class="terrain" style="font-weight:bold"></span></div>
<div>
FR.
<span style="font-size:34px;font-weight:bold" class="montant"></span>
- <span class="last_encherisseur"></span>
</div>
<hr/>
<div>
<div style="font-size:10px;width:49%;float:left" class="list_encherisseurs"></div>
<div style="font-size:10px;width:49%;float:right;color:darkgrey" class="list_exit"></div>
</div>
<div class="messages"></div>
</div>
<div id="actions"></div>
<div class="mobile"></div>
<script language="javascript">
// On detecte le type de donnees a charger
/*let nomPlateau = "data-monopoly.json";
if (location.href.indexOf("plateau=")!==-1) {
nomPlateau = "data-monopoly-" + location.href.substring(location.href.indexOf("plateau=")+8) + ".json";
}*/
let debug = false;
$(function(){
$('#idCreationGame').tabs();
$('#idMontantParc').hide();
startMonopoly(debug)
if($('.mobile').is(':visible')) {
DrawerFactory.setSize(950);
}
});
</script>
</body>
</html>