forked from halo-battle/game
Version 0.9a
This commit is contained in:
parent
d5c122a2c5
commit
59fbc7104e
141 changed files with 8686 additions and 1156 deletions
|
|
@ -81,7 +81,8 @@ if ($labo > 0) {
|
|||
$template->assign_var_from_handle('RESSOURCES', 'ressourcestpl');
|
||||
$CHAINE = '';
|
||||
if (!empty($fileTec[0])) {
|
||||
for ($i=0 ; $i<count($fileTec) ; $i++) {
|
||||
$l = count($fileTec);
|
||||
for ($i=0 ; $i<$l ; $i++) {
|
||||
if ($fileTec[$i] != 'e') $template->assign_block_vars('file',array('NOM' => $technolo[$fileTec[$i]-1], 'NUM' => $fileTec[$i]));
|
||||
else $CHAINE = ' <br /> <a href="annul_tec.php?tec=e"><i>Arrêter de produire à la chaîne</i></a>';
|
||||
}
|
||||
|
|
@ -98,7 +99,7 @@ if ($labo > 0) {
|
|||
if (${$nom_bdd} > 0) $niveau = '(Niveau '.${$nom_bdd}.')'; else $niveau = '';
|
||||
$n=(${$nom_bdd}-1); $b=ceil(pow(2,$n)*500); $c=ceil(pow(2,$n)*150);
|
||||
if (is_array($fileTec) && $tec == $i+1) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche en cours, temps restant : <span id="axion"></span><br><script type="text/javascript">reste('.$tr.');</script>'; }
|
||||
elseif (is_array($fileTec) && ereg(($i+1).',',implode(',', $fileTec).',')) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche dans la file d\'attente'; }
|
||||
elseif (is_array($fileTec) && ereg(','.($i+1).',',','.implode(',', $fileTec).',')) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche dans la file d\'attente'; }
|
||||
elseif($bat == 7) $action = 'Le laboratoire est en cours d\'évolution';
|
||||
else $action = verification_des_ress($i+1, $metal, $cristal, $hydrogene, 0, $b, $c);
|
||||
if (!empty($technolo[$i])) $template->assign_block_vars('technologie', array('IMAGE' => $technoli[$i], 'NOM' => $technolo[$i], 'NUM' => $i, 'NIVEAU' => $niveau, 'DESCRIPTION' => $technode[$i], 'BESOIN' => ressources($metal, $cristal, $hydrogene, 0, $b, $c, $mine_m, $mine_c, $mine_h), 'TEMPS' => sec(ceil((420*2*($informatique+1))/pow(1.25,($labo-1)))), 'ACTION' => $action));
|
||||
|
|
@ -111,7 +112,7 @@ if ($labo > 0) {
|
|||
if (${$nom_bdd} > 0) $niveau = '(Niveau '.${$nom_bdd}.')'; else $niveau = '';
|
||||
$n=(${$nom_bdd}-1); $a=ceil(pow(2,$n)*500); $b=ceil(pow(2,$n)*750); $c=ceil(pow(2,$n)*100);
|
||||
if (is_array($fileTec) && $tec == $i+1) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche en cours, temps restant : <span id="axion"></span><br><script type="text/javascript">reste('.$tr.');</script>'; }
|
||||
elseif (is_array($fileTec) && ereg(($i+1).',',implode(',', $fileTec).',')) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche dans la file d\'attente'; }
|
||||
elseif (is_array($fileTec) && ereg(','.($i+1).',',','.implode(',', $fileTec).',')) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche dans la file d\'attente'; }
|
||||
elseif($bat == 7) $action = 'Le laboratoire est en cours d\'évolution';
|
||||
else $action = verification_des_ress($i+1, $metal, $cristal, $hydrogene, $a, $b, $c);
|
||||
if (!empty($technolo[$i])) $template->assign_block_vars('technologie', array('TEMPS' => sec(ceil((600*2*($detection+1))/pow(1.25,($labo-2)))), 'BESOIN' => ressources($metal, $cristal, $hydrogene, $a, $b, $c, $mine_m, $mine_c, $mine_h), 'IMAGE' => $technoli[$i], 'NOM' => $technolo[$i], 'NUM' => $i, 'NIVEAU' => $niveau, 'DESCRIPTION' => $technode[$i], 'ACTION' => $action));
|
||||
|
|
@ -124,7 +125,7 @@ if ($labo > 0) {
|
|||
if (${$nom_bdd} > 0) $niveau = '(Niveau '.${$nom_bdd}.')'; else $niveau = '';
|
||||
$n=(${$nom_bdd}-1); $a=ceil(pow(2,$n)*2500); $b=ceil(pow(2,$n)*500);
|
||||
if (is_array($fileTec) && $tec == $i+1) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche en cours, temps restant : <span id="axion"></span><br><script type="text/javascript">reste('.$tr.');</script>'; }
|
||||
elseif (is_array($fileTec) && ereg(($i+1).',',implode(',', $fileTec).',')) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche dans la file d\'attente'; }
|
||||
elseif (is_array($fileTec) && ereg(','.($i+1).',',','.implode(',', $fileTec).',')) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche dans la file d\'attente'; }
|
||||
elseif($bat == 7) $action = 'Le laboratoire est en cours d\'évolution';
|
||||
else $action = verification_des_ress($i+1, $metal, $cristal, $hydrogene, $a, $b, $c);
|
||||
if (!empty($technolo[$i])) $template->assign_block_vars('technologie', array('TEMPS' => sec(ceil((1500*2*($armement+1))/pow(1.25,($labo-5)))), 'BESOIN' => ressources($metal, $cristal, $hydrogene, $a, $b, 0, $mine_m, $mine_c, $mine_h), 'IMAGE' => $technoli[$i], 'NOM' => $technolo[$i], 'NUM' => $i, 'NIVEAU' => $niveau, 'DESCRIPTION' => $technode[$i], 'ACTION' => $action));
|
||||
|
|
@ -138,7 +139,7 @@ if ($labo > 0) {
|
|||
if (${$nom_bdd} > 0) $niveau = '(Niveau '.${$nom_bdd}.')'; else $niveau = '';
|
||||
$a=ceil(pow(2,$n)*4000); $b=ceil(pow(2,$n)*1500);
|
||||
if (is_array($fileTec) && $tec == $i+1) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche en cours, temps restant : <span id="axion"></span><br><script type="text/javascript">reste('.$tr.');</script>'; }
|
||||
elseif (is_array($fileTec) && ereg(($i+1).',',implode(',', $fileTec).',')) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche dans la file d\'attente'; }
|
||||
elseif (is_array($fileTec) && ereg(','.($i+1).',',','.implode(',', $fileTec).',')) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche dans la file d\'attente'; }
|
||||
elseif($bat == 7) $action = 'Le laboratoire est en cours d\'évolution';
|
||||
else $action = verification_des_ress($i+1, $metal, $cristal, $hydrogene, $a, $b, $c);
|
||||
if (!empty($technolo[$i])) $template->assign_block_vars('technologie', array('TEMPS' => sec(ceil((1710*2*($blindage+1))/pow(1.25,($labo-4)))), 'BESOIN' => ressources($metal, $cristal, $hydrogene, $a, $b, 0, $mine_m, $mine_c, $mine_h), 'IMAGE' => $technoli[$i], 'NOM' => $technolo[$i], 'NUM' => $i, 'NIVEAU' => $niveau, 'DESCRIPTION' => $technode[$i], 'ACTION' => $action));
|
||||
|
|
@ -152,7 +153,7 @@ if ($labo > 0) {
|
|||
if (${$nom_bdd} > 0) $niveau = '(Niveau '.${$nom_bdd}.')'; else $niveau = '';
|
||||
$a=ceil(pow(2,$n)*2000); $b=ceil(pow(2,$n)*1500); $c=ceil(pow(2,$n)*300);
|
||||
if (is_array($fileTec) && $tec == $i+1) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche en cours, temps restant : <span id="axion"></span><br><script type="text/javascript">reste('.$tr.');</script>'; }
|
||||
elseif (is_array($fileTec) && ereg(($i+1).',',implode(',', $fileTec).',')) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche dans la file d\'attente'; }
|
||||
elseif (is_array($fileTec) && ereg(','.($i+1).',',','.implode(',', $fileTec).',')) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche dans la file d\'attente'; }
|
||||
elseif($bat == 7) $action = 'Le laboratoire est en cours d\'évolution';
|
||||
else $action = verification_des_ress($i+1, $metal, $cristal, $hydrogene, $a, $b, $c);
|
||||
if (!empty($technolo[$i])) $template->assign_block_vars('technologie', array('TEMPS' => sec(ceil((900*2*($energie_t+1))/pow(1.25,($labo-2)))), 'BESOIN' => ressources($metal, $cristal, $hydrogene, $a, $b, $c, $mine_m, $mine_c, $mine_h), 'IMAGE' => $technoli[$i], 'NOM' => $technolo[$i], 'NUM' => $i, 'NIVEAU' => $niveau, 'DESCRIPTION' => $technode[$i], 'ACTION' => $action));
|
||||
|
|
@ -166,7 +167,7 @@ if ($labo > 0) {
|
|||
if (${$nom_bdd} > 0) $niveau = '(Niveau '.${$nom_bdd}.')'; else $niveau = '';
|
||||
$a=ceil(pow(2,$n)*1400); $b=ceil(pow(2,$n)*400);
|
||||
if (is_array($fileTec) && $tec == $i+1) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche en cours, temps restant : <span id="axion"></span><br><script type="text/javascript">reste('.$tr.');</script>'; }
|
||||
elseif (is_array($fileTec) && ereg(($i+1).',',implode(',', $fileTec).',')) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche dans la file d\'attente'; }
|
||||
elseif (is_array($fileTec) && ereg(','.($i+1).',',','.implode(',', $fileTec).',')) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche dans la file d\'attente'; }
|
||||
elseif($bat == 7) $action = 'Le laboratoire est en cours d\'évolution';
|
||||
else $action = verification_des_ress($i+1, $metal, $cristal, $hydrogene, $a, $b, $c);
|
||||
if (!empty($technolo[$i])) $template->assign_block_vars('technologie', array('TEMPS' => sec(ceil((510*2*($reacteur+1))/pow(1.25,($labo-2)))), 'BESOIN' => ressources($metal, $cristal, $hydrogene, $a, $b, 0, $mine_m, $mine_c, $mine_h), 'IMAGE' => $technoli[$i], 'NOM' => $technolo[$i], 'NUM' => $i, 'NIVEAU' => $niveau, 'DESCRIPTION' => $technode[$i], 'ACTION' => $action));
|
||||
|
|
@ -180,7 +181,7 @@ if ($labo > 0) {
|
|||
if (${$nom_bdd} > 0) $niveau = '(Niveau '.${$nom_bdd}.')'; else $niveau = '';
|
||||
$a=ceil(pow(2,$n)*3000); $b=ceil(pow(2,$n)*2100); $c=ceil(pow(2,$n)*750);
|
||||
if (is_array($fileTec) && $tec == $i+1) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche en cours, temps restant : <span id="axion"></span><br><script type="text/javascript">reste('.$tr.');</script>'; }
|
||||
elseif (is_array($fileTec) && ereg(($i+1).',',implode(',', $fileTec).',')) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche dans la file d\'attente'; }
|
||||
elseif (is_array($fileTec) && ereg(','.($i+1).',',','.implode(',', $fileTec).',')) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche dans la file d\'attente'; }
|
||||
elseif($bat == 7) $action = 'Le laboratoire est en cours d\'évolution';
|
||||
else $action = verification_des_ress($i+1, $metal, $cristal, $hydrogene, $a, $b, $c);
|
||||
if (!empty($technolo[$i])) $template->assign_block_vars('technologie', array('TEMPS' => sec(ceil((1650*2*($reacteur_f+1))/pow(1.25,($labo-4)))), 'BESOIN' => ressources($metal, $cristal, $hydrogene, $a, $b, $c, $mine_m, $mine_c, $mine_h), 'IMAGE' => $technoli[$i], 'NOM' => $technolo[$i], 'NUM' => $i, 'NIVEAU' => $niveau, 'DESCRIPTION' => $technode[$i], 'ACTION' => $action));
|
||||
|
|
@ -194,7 +195,7 @@ if ($labo > 0) {
|
|||
if (${$nom_bdd} > 0) $niveau = '(Niveau '.${$nom_bdd}.')'; else $niveau = '';
|
||||
$a=ceil(pow(2,$n)*5000); $b=ceil(pow(2,$n)*4000); $c=ceil(pow(2,$n)*1500);
|
||||
if (is_array($fileTec) && $tec == $i+1) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche en cours, temps restant : <span id="axion"></span><br><script type="text/javascript">reste('.$tr.');</script>'; }
|
||||
elseif (is_array($fileTec) && ereg(($i+1).',',implode(',', $fileTec).',')) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche dans la file d\'attente'; }
|
||||
elseif (is_array($fileTec) && ereg(','.($i+1).',',','.implode(',', $fileTec).',')) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche dans la file d\'attente'; }
|
||||
elseif($bat == 7) $action = 'Le laboratoire est en cours d\'évolution';
|
||||
else $action = verification_des_ress($i+1, $metal, $cristal, $hydrogene, $a, $b, $c);
|
||||
if (!empty($technolo[$i])) $template->assign_block_vars('technologie', array('TEMPS' => sec(ceil((2400*2*($reacteur_ff+1))/pow(1.25,($labo-6)))), 'BESOIN' => ressources($metal, $cristal, $hydrogene, $a, $b, $c, $mine_m, $mine_c, $mine_h), 'IMAGE' => $technoli[$i], 'NOM' => $technolo[$i], 'NUM' => $i, 'NIVEAU' => $niveau, 'DESCRIPTION' => $technode[$i], 'ACTION' => $action));
|
||||
|
|
@ -208,7 +209,7 @@ if ($labo > 0) {
|
|||
if (${$nom_bdd} > 0) $niveau = '(Niveau '.${$nom_bdd}.')'; else $niveau = '';
|
||||
$a=ceil(pow(2,$n)*800); $b=ceil(pow(2,$n)*1000);
|
||||
if (is_array($fileTec) && $tec == $i+1) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche en cours, temps restant : <span id="axion"></span><br><script type="text/javascript">reste('.$tr.');</script>'; }
|
||||
elseif (is_array($fileTec) && ereg(($i+1).',',implode(',', $fileTec).',')) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche dans la file d\'attente'; }
|
||||
elseif (is_array($fileTec) && ereg(','.($i+1).',',','.implode(',', $fileTec).',')) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche dans la file d\'attente'; }
|
||||
elseif($bat == 7) $action = 'Le laboratoire est en cours d\'évolution';
|
||||
else $action = verification_des_ress($i+1, $metal, $cristal, $hydrogene, $a, $b, $c);
|
||||
if (!empty($technolo[$i])) $template->assign_block_vars('technologie', array('TEMPS' => sec(ceil((360*2*($medecine+1))/pow(1.25,($labo-1)))), 'BESOIN' => ressources($metal, $cristal, $hydrogene, $a, $b, 0, $mine_m, $mine_c, $mine_h), 'IMAGE' => $technoli[$i], 'NOM' => $technolo[$i], 'NUM' => $i, 'NIVEAU' => $niveau, 'DESCRIPTION' => $technode[$i], 'ACTION' => $action));
|
||||
|
|
@ -222,7 +223,7 @@ if ($labo > 0) {
|
|||
if (${$nom_bdd} > 0) $niveau = '(Niveau '.${$nom_bdd}.')'; else $niveau = '';
|
||||
$a=ceil(pow(2,$n)*2600); $b=ceil(pow(2,$n)*2600);
|
||||
if (is_array($fileTec) && $tec == $i+1) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche en cours, temps restant : <span id="axion"></span><br><script type="text/javascript">reste('.$tr.');</script>'; }
|
||||
elseif (is_array($fileTec) && ereg(($i+1).',',implode(',', $fileTec).',')) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche dans la file d\'attente'; }
|
||||
elseif (is_array($fileTec) && ereg(','.($i+1).',',','.implode(',', $fileTec).',')) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche dans la file d\'attente'; }
|
||||
elseif($bat == 7) $action = 'Le laboratoire est en cours d\'évolution';
|
||||
else $action = verification_des_ress($i+1, $metal, $cristal, $hydrogene, $a, $b, $c);
|
||||
if (!empty($technolo[$i])) $template->assign_block_vars('technologie', array('TEMPS' => sec(ceil((4410*2*($tactique+1))/pow(1.25,($labo-3)))), 'BESOIN' => ressources($metal, $cristal, $hydrogene, $a, $b, 0, $mine_m, $mine_c, $mine_h), 'IMAGE' => $technoli[$i], 'NOM' => $technolo[$i], 'NUM' => $i, 'NIVEAU' => $niveau, 'DESCRIPTION' => $technode[$i], 'ACTION' => $action));
|
||||
|
|
@ -236,7 +237,7 @@ if ($labo > 0) {
|
|||
if (${$nom_bdd} > 0) $niveau = '(Niveau '.${$nom_bdd}.')'; else $niveau = '';
|
||||
$a=ceil(pow(3,$n)*5200); $b=ceil(pow(3,$n)*4250); $c=ceil(pow(3,$n)*850);
|
||||
if (is_array($fileTec) && $tec == $i+1) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche en cours, temps restant : <span id="axion"></span><br><script type="text/javascript">reste('.$tr.');</script>'; }
|
||||
elseif (is_array($fileTec) && ereg(($i+1).',',implode(',', $fileTec).',')) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche dans la file d\'attente'; }
|
||||
elseif (is_array($fileTec) && ereg(','.($i+1).',',','.implode(',', $fileTec).',')) { $tr=$fileTemps_t[0]+$fileTemps_t[1]-time(); $action = 'Recherche dans la file d\'attente'; }
|
||||
elseif($bat == 7) $action = 'Le laboratoire est en cours d\'évolution';
|
||||
else $action = verification_des_ress($i+1, $metal, $cristal, $hydrogene, $a, $b, $c);
|
||||
if (!empty($technolo[$i])) $template->assign_block_vars('technologie', array('TEMPS' => sec(ceil((5000*2*($spartan+1))/pow(1.25,($labo-8)))), 'BESOIN' => ressources($metal, $cristal, $hydrogene, $a, $b, $c, $mine_m, $mine_c, $mine_h), 'IMAGE' => $technoli[$i], 'NOM' => $technolo[$i], 'NUM' => $i, 'NIVEAU' => $niveau, 'DESCRIPTION' => $technode[$i], 'ACTION' => $action));
|
||||
|
|
@ -244,21 +245,17 @@ if ($labo > 0) {
|
|||
|
||||
$template->pparse('labo');
|
||||
}
|
||||
else echo '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="fr">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
||||
<meta http-equiv="Content-Language" content="fr" />
|
||||
<meta http-equiv="Cache-Control" content="no-cache" />
|
||||
<meta http-equiv="Pragma" content="no-cache" />
|
||||
<meta name="Description" lang="fr" content="Jeu en ligne de simulation de guerre spatiale" />
|
||||
<meta name="Author" content="Halo-Battle" />
|
||||
<link rel="shortcut icon" type="image/x-icon" href="favicon.ico" />
|
||||
<script type="text/javascript" src="time.js"></script>
|
||||
<link rel="stylesheet" media="screen" type="text/css" title="design" href="descriptions/diz/base.css" />
|
||||
<title> ::Halo-Battle:: Bêta - Laboratoire</title>
|
||||
</head>
|
||||
<body>
|
||||
<br /><br /><br /><div class="centre"><table style="margin-left: auto; margin-right: auto;"><tr><td>Vous devez d\'abord construire un centre de recherche !</td></tr></table></div>
|
||||
</body></html>';
|
||||
else {
|
||||
$template->set_filenames(array('ressourcestpl' => 'ressources.tpl'));
|
||||
$template->assign_vars( array('RES_IMAGE' => $RES_IMAGE, 'NOM_METAL' => $NOM_METAL, 'NOM_CRISTAL' => $NOM_CRISTAL, 'NOM_HYDROGENE' => $NOM_HYDROGENE, 'NOM_ENERGIE' => $NOM_ENERGIE, 'RES_METAL' => $RES_METAL, 'RES_CRISTAL' => $RES_CRISTAL, 'RES_HYDROGENE' => $RES_HYDROGENE, 'RES_ENERGIE' => $RES_ENERGIE, 'ERREUR' => $ERREUR, 'HEADER' => $HEADER, 'PUB' => $PUB));
|
||||
for ($i=0 ; $i<count($Aplan_value) ; $i++) {
|
||||
$template->assign_block_vars('planetes',array('RES_VALUE' => $Aplan_value[$i], 'RES_MORE' => $Aplan_more[$i], 'RES_REF' => $Aplan_ref[$i]));
|
||||
}
|
||||
|
||||
$template->set_filenames(array('manque' => 'manque.tpl'));
|
||||
$template->assign_var_from_handle('RESSOURCES', 'ressourcestpl');
|
||||
|
||||
$template->assign_vars( array('TEXTE' => 'Vous devez d\'abord construire un centre de recherche !', 'PUB' => $PUB));
|
||||
$template->pparse('manque');
|
||||
}
|
||||
?>
|
||||
Loading…
Add table
Add a link
Reference in a new issue