-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.php
executable file
·405 lines (323 loc) · 15.3 KB
/
index.php
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
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
<?php
define('IN_PHPBB', true);
$phpbb_root_path = '../bbs/';
include($phpbb_root_path . 'extension.inc');
include($phpbb_root_path . 'common.'.$phpEx);
//
// Start session management
//
$userdata = session_pagestart($user_ip, PAGE_PROFILE);
init_userprefs($userdata);
$title='Capture the flag';
$css='../css/style2.css';
$include='../bbs/includes/';
include($include.'config.php');//infos SQL, version, error etc...
mysql_connect($serveur, $name, $password);
mysql_select_db($db);
include($include.'haut.php'); //<DOCTYPE...
include($include.'left.php'); // Header + menu
?>
<!-- main content -->
<td valign="top">
<table width="630" border="0" cellspacing="0" cellpadding="5">
<tr>
<td valign="top">
<table width="435" border="0" cellpadding="0" cellspacing="0">
<tr>
<td align="left">
<img src="b_ctf.png" alt="b_ctf" />
</td>
</tr>
<tr>
<td background="/img/bg_tile_petitbleu.gif" bgcolor="#DCEAF5" align="center">
<table width="100%" border="0" cellspacing="0" cellpadding="5">
<tr>
<td>
<div align="center">
<table border="0" align="center" cellpadding="5" cellspacing="0" class="subnav">
<tr>
<td><table border="0" cellspacing="0" cellpadding="0">
<tr>
<td><img src="/img/bt-left.gif" width="13" height="15" /></td>
<td valign="middle" bgcolor="#78AADB"><a href="#htp">Comment jouer ?</a></td>
<td><img src="/img/bt-right.gif" width="7" height="15" /></td>
</tr>
</table></td>
<td><table border="0" cellspacing="0" cellpadding="0">
<tr>
<td><img src="/img/bt-left.gif" width="13" height="15" /></td>
<td valign="middle" bgcolor="#78AADB"><a href="#gameplay">Le gameplay</a></td>
<td><img src="/img/bt-right.gif" width="7" height="15" /></td>
</tr>
</table></td>
<td><table border="0" cellspacing="0" cellpadding="0">
<tr>
<td><img src="/img/bt-left.gif" width="13" height="15" /></td>
<td valign="middle" bgcolor="#78AADB"><a href="#top20">Les Meilleurs</a></td>
<td><img src="/img/bt-right.gif" width="7" height="15" /></td>
</tr>
</table></td>
</tr>
</table>
</div>
<br />
<b>Capture the flag</b> est un pur jeu de strategie-course <:D !
<br /><br />
Le principe est simple: choper le drapeau et le ramener dans le camps adverse !
<br />
Qui sera le plus grand voleur ? Qui ira le plus vite ? <b>@@</b>
A toi de bien gérer, et... bonne chance <b>;)</b>
<br/><br/>
Le premier du classement gagne l'avatar <b>vishnu</b>.
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td><img src="/img/bg_bottom_petitbleu.gif" width="435" height="11"></td>
</tr>
<tr><td><img src="/img/spacer.gif" width="435" height="10"></td></tr>
<tr>
<td align="left"><img src="/img/bg_top_petitbleu.gif" width="435" height="11"></td>
</tr>
<tr>
<td background="/img/bg_tile_petitbleu.gif" bgcolor="#DCEAF5">
<table width="100%" border="0" cellspacing="0" cellpadding="5">
<tr>
<td>
<a name="htp"></a>
<div align="center"><span class="titrebleu">Comment jouer ?</span><br /><br />
</div>
<b>Capture the flag</b> est un jeu jouable que quand les modos / animateurs sont là ...<br />
<br />
Un modérateur / animateur lance une annonce et ceux qui veulent participer doivent aller dans la salle indiquée dans l'annonce<br /><br /><br />
<b>But du jeu : Vous devez voler le drapeau qui se trouve au milieu de la map et le ramener dans le camps adverse en évitant les joueurs adverses.</b>
<br />
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td><img src="/img/bg_bottom_petitbleu.gif" width="435" height="11"></td>
</tr>
<tr><td><img src="/img/spacer.gif" width="435" height="10"></td></tr>
<tr>
<td align="left"><img src="/img/bg_top_petitbleu.gif" width="435" height="11"></td>
</tr>
<tr>
<td background="/img/bg_tile_petitbleu.gif" bgcolor="#DCEAF5">
<table width="100%" border="0" cellspacing="0" cellpadding="5">
<tr>
<td>
<a name="gameplay"></a>
<div align="center"class="titrebleu">Game Play</div>
<br />
<b>Capture the flag</b> se joue avec le clavier:
Tu dois voler le drapeau et éviter de te faire toucher sinon c'est le drame : si un joueur adverse te touche, il te vole le drapeau à son tour !
<br /><br />
Chaque fois que vous gagnez 5 manches, la partie est finie et ton score <b>Capture the flag</b> augmente d'un point.<br />
Chaque fois que tu perds, ton score... reste comme il est ! <b>:')</b>
<br />
<br />
<b>Notes:</b><br />
- Tu as toujours une chance de gagner/perdre .<br />
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td><img src="/img/bg_bottom_petitbleu.gif" width="435" height="11"></td>
</tr>
<tr><td><img src="/img/spacer.gif" width="435" height="10"></td></tr>
<tr>
<td><img src="/img/bg_top_petitbleu.gif" width="435" height="11"></td>
</tr>
<tr>
<td background="/img/bg_tile_petitbleu.gif" bgcolor="#DCEAF5">
<table width="100%" border="0" cellspacing="0" cellpadding="5">
<tr>
<td>
<div align="center">
<a name="top20"></a>
<span class="titrebleu">Les 20 meilleurs voleurs de l'Archipel</span>
<br />
<em>"Ils volent tout le temps le drapeau ? Ou pas ... <:D"</em>
<br />
<br />
<table width='100%' border='0' cellpadding="3" cellspacing="0">
<tr>
<td valign="top" width="1%" align="center" nowrap="nowrap"><b>#</b></td>
<td valign="top" align="center" nowrap="nowrap"><b>Membre</b></td>
<td valign="top" width="1%" align="center" nowrap="nowrap"><b>Score</b></td>
<td valign="top" align="center" nowrap="nowrap"><b>Map</b></td>
</tr>
<?php
$i = 0;
$sql = 'SELECT * FROM phpbb_users WHERE classement_capture >= 1 ORDER BY classement_capture DESC LIMIT 20';
$req = mysql_query($sql) or die('Erreur SQL !<br>'.$sql.'<br>'.mysql_error());
while($data = mysql_fetch_assoc($req))
{
$i++;
if($i == "1" OR $i == "3" OR $i == "5" OR $i == "7" OR $i == "9" OR $i == "11" OR $i == "13" OR $i == "15" OR $i == "17" OR $i == "19")
{
echo '<tr bgcolor=#EEF5FA>';
}
else
{
echo '<tr>';
}
?>
<?php
echo '<td align="center" valign="top" ><b>'.$i.'<b></td><td align="center" valign="top" ><a href="/annuaire/?mid='.$data['user_id'].'">'.$data['username'].'</a></td><td align="center" valign="top" ><b>'.$data['classement_capture'].'</b></td><td align="center" valign="top" nowrap="nowrap">Escapade vers bacteria</td></tr>';
} ?>
<?php
$o = 0;
$sql = 'SELECT * FROM phpbb_users WHERE classement_capture >= 1 ORDER BY classement_capture DESC LIMIT 20';
$req = mysql_query($sql) or die('Erreur SQL !<br>'.$sql.'<br>'.mysql_error());
while($data = mysql_fetch_assoc($req))
{
$o++;
$quetezzz = mysql_query('UPDATE phpbb_users SET rank_capture = "'.$o.'" WHERE username = "'.$data['username'].'"');
}
?>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td><img src="/img/bg_bottom_petitbleu.gif" width="435" height="11"></td>
</tr>
<tr><td><img src="/img/spacer.gif" width="435" height="10"></td></tr>
<tr>
<td><img src="/img/bg_top_petitbleu.gif" width="435" height="11"></td>
</tr>
<tr>
<td background="/img/bg_tile_petitbleu.gif" bgcolor="#DCEAF5">
<table width="100%" border="0" cellspacing="0" cellpadding="5">
<tr>
<td>
<div align="center">
<a name="top20"></a>
<span class="titrebleu">Les 10 meilleurs groupes de CTF ! </span>
<br />
<em>"Plus on est de fous..."</em>
<br />
<br />
<table width='100%' border='0' cellpadding="3" cellspacing="0">
<tr>
<td valign="top" width="1%" align="center" nowrap="nowrap"><b>#</b></td>
<td valign="top" align="center" nowrap="nowrap"><b>Groupe</b></td>
<td valign="top" width="1%" align="center" nowrap="nowrap"><b>Score</b></td>
</tr>
<?php
$sqlx = 'SELECT * FROM phpbb_users WHERE classement_capture >= 1';
$reqx = mysql_query($sqlx) or die('Erreur SQL !<br>'.$sqlx.'<br>'.mysql_error());
while($datax = mysql_fetch_assoc($reqx))
{
$kete = mysql_query('UPDATE phpbb_user_group SET c_ctf = "'.$datax['classement_capture'].'" WHERE user_id = "'.$datax['user_id'].'"');
}
?>
<?php
mysql_query('UPDATE phpbb_groups SET rank_ctf = "0"');
$sql = 'SELECT * FROM phpbb_user_group WHERE c_ctf >= 1';
$req = mysql_query($sql) or die('Erreur SQL !<br>'.$sql.'<br>'.mysql_error());
while($data = mysql_fetch_assoc($req))
{
$fok = mysql_query('SELECT * FROM phpbb_groups WHERE group_id = "'.$data['group_id'].'"');
$fok = mysql_fetch_assoc($fok);
$total = $data['c_ctf'] + $fok['rank_ctf'];
$ket = mysql_query('UPDATE phpbb_groups SET rank_ctf = "'.$total.'" WHERE group_id = "'.$fok['group_id'].'"');
}
?>
<?php
$b = 0;
$sql = 'SELECT * FROM phpbb_groups WHERE rank_ctf >= 1 ORDER BY rank_ctf DESC LIMIT 10';
$req = mysql_query($sql) or die('Erreur SQL !<br>'.$sql.'<br>'.mysql_error());
while($data = mysql_fetch_assoc($req))
{
$b++;
if($b == "1" OR $b == "3" OR $b == "5" OR $b == "7" OR $b == "9")
{
echo '<tr bgcolor=#EEF5FA>';
}
else
{
echo '<tr>';
}
?>
<?php
echo '<td align="center" valign="top" ><b>'.$b.'<b></td><td align="center" valign="top" ><a href="/groups/?gid='.$data['group_id'].'">'.stripslashes($data['group_name']).'</a></td><td align="center" valign="top" ><b>'.$data['rank_ctf'].'</b></td></tr>';
$kekete = mysql_query('UPDATE phpbb_groups SET c_ctf = "'.$b.'" WHERE group_id = "'.$data['group_id'].'"');
} ?>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td><img src="/img/bg_bottom_petitbleu.gif" width="435" height="11"></td>
</tr>
</table>
</td>
<td valign="top">
<table width="168" border="0" cellpadding="0" cellspacing="0">
<tr>
<td align="left"><img src="/img/spacer.gif" width="12" height="19"><br>
<img src="/img/ensavoirplus_top.gif" width="168" height="37"></td>
</tr>
<tr>
<td valign="top" bgcolor="#A4C4E3">
<table width="168" border="0" cellspacing="0" cellpadding="5">
<tr>
<td valign="top">
<img src="/img/coldroite_puce.gif" width="17" height="12" border="0" align="absmiddle">
<b>Capture the flag</b> est actuellement en version alpha (version de test)
<br />
<br />
<img src="/img/coldroite_puce.gif" width="17" height="12" border="0" align="absmiddle">
<b>Capture the flag (alpha)</b> est accessible à tous les membres.
<br />
<br />
<img src="/img/coldroite_puce.gif" width="17" height="12" border="0" align="absmiddle">
Le classement est mis à jour <b>en temps reel !</b>.
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td><img src="/img/coldroite_bottom.gif" width="168" height="11"></td>
</tr>
</table>
<table width="168" border="0" cellpadding="0" cellspacing="0">
<tr>
<td align="left"><img src="/img/goodies_top.gif"></td>
</tr>
<tr>
<td valign="top" bgcolor="#A4C4E3">
<table width="168" border="0" cellspacing="0" cellpadding="5">
<tr>
<td valign="top">
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td><img src="/img/coldroite_bottom.gif" width="168" height="11"></td>
</tr>
</table>
</td>
</tr>
</table>
<?php
include('../bbs/includes/bas.php');
?>