Version 1.8

This commit is contained in:
nemunaire 2008-11-03 12:00:00 +01:00
commit 5f81f76b17
184 changed files with 78335 additions and 736 deletions

View file

@ -42,22 +42,15 @@ for ($i = 1; $i <= MAX_PLANETE; $i++) {
$bdd->connexion();
$bdd->escape($g);
$bdd->escape($s);
$resultat = $bdd->query("SELECT id FROM $table_planete WHERE galaxie = '$g' AND ss = '$s' AND position = '$i';");
$resultat = $bdd->query("SELECT id FROM $table_planete WHERE galaxie = $g AND ss = $s AND position = $i;");
if($resultat) {
$d = $bdd->unique_query("SELECT id_user, nom_planete, debris_met, debris_cri FROM $table_planete WHERE galaxie = '$g' AND ss = '$s' AND position = '$i';");
$id_user = $d['id_user'];
$e = $bdd->unique_query("SELECT pseudo, race, id_alliance FROM $table_user WHERE id = '$id_user'");
if ($e['id_alliance']) {
$alliId = $e['id_alliance'];
$eA = $bdd->unique_query("SELECT tag FROM $table_alliances WHERE id = '$alliId';");
}
else $eA = false;
$d = $bdd->unique_query("SELECT P.nom_planete, P.debris_met, P.debris_cri, U.pseudo, U.race, U.id_alliance, A.tag FROM $table_planete P INNER JOIN $table_user U ON U.id = P.id_user LEFT OUTER JOIN $table_alliances A ON A.id = U.id_alliance WHERE galaxie = $g AND ss = $s AND position = $i;");
$bdd->deconnexion();
if ($e['race'] == 'covenant') $ra = '(c)';
elseif ($auth_level >= 6 && md5($e['race']) == '34c19b21bd4a3dda389e767d32fe9779') $ra = '(f)';
if ($d['race'] == 'covenant') $ra = '(c)';
elseif ($auth_level >= 6 && md5($d['race']) == '34c19b21bd4a3dda389e767d32fe9779') $ra = '(f)';
else $ra = '(h)';
$TEMP_carte[] = array($i, htmlspecialchars($d['nom_planete']), $d['debris_met'], $d['debris_cri'], $ra, $e['pseudo'], '<a href="?p=envoyer&amp;d='.$e['pseudo'].'" class="msg"><span>Message</span></a>', $eA['tag']);
$TEMP_carte[] = array($i, htmlspecialchars($d['nom_planete']), $d['debris_met'], $d['debris_cri'], $ra, $d['pseudo'], '<a href="?p=envoyer&amp;d='.$d['pseudo'].'" class="msg"><span>Message</span></a>', $d['tag']);//, $eA['tag']);
}
else {
$bdd->deconnexion();