forked from halo-battle/game
MàJ des descriptions des tech covies pour les vaisseaux et affichage des bons noms
This commit is contained in:
parent
4fedde4cf9
commit
2269a56ce5
6 changed files with 23 additions and 21 deletions
|
|
@ -44,13 +44,13 @@ if (SURFACE == "asteroide") {
|
|||
}
|
||||
|
||||
|
||||
function traiterBrancheTechnologie($TEMP_liste, $branche, $i)
|
||||
function traiterBrancheTechnologie($TEMP_liste, $branche, $i, $race)
|
||||
{
|
||||
global $LANG, $planete;
|
||||
|
||||
foreach ($i as $key => $id) {
|
||||
if (is_array($id)) {
|
||||
$TEMP_liste = traiterBrancheTechnologie($TEMP_liste, $branche, $id);
|
||||
$TEMP_liste = traiterBrancheTechnologie($TEMP_liste, $branche, $id, $race);
|
||||
} else {
|
||||
$niveau = dTechnologies::niveau_du_joueur($branche, $id, $planete);
|
||||
$niveau_max = dTechnologies::niveau_max($branche, $id, $planete, $LANG);
|
||||
|
|
@ -61,7 +61,7 @@ function traiterBrancheTechnologie($TEMP_liste, $branche, $i)
|
|||
'branche' => $branche,
|
||||
'niveau' => $niveau,
|
||||
'niveau_max' => $niveau_max,
|
||||
'etat' => dTechnologies::needed($object, $planete, true)
|
||||
'etat' => dTechnologies::needed($object, $planete, true, $race)
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
@ -72,7 +72,7 @@ $TEMP_liste = array();
|
|||
$branche = 0;
|
||||
while ($branche < 9) {
|
||||
$TEMP_liste[$branche] = array();
|
||||
$TEMP_liste = traiterBrancheTechnologie($TEMP_liste, $branche, dTechnologies::type($branche, $planete->race));
|
||||
$TEMP_liste = traiterBrancheTechnologie($TEMP_liste, $branche, dTechnologies::type($branche, $planete->race), $race);
|
||||
$branche++;
|
||||
}
|
||||
$template->assign('technologies', $TEMP_liste);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue