Fix Lang + Fix train troops in greatbarraks and great stable + fix ally message + refactor battle system

Fix Lang + Fix train troops in greatbarraks and great stable + fix ally message + refactor battle system #219
This commit is contained in:
novgorodschi catalin
2026-07-23 08:25:32 +03:00
parent 8db3032293
commit da4f203aa1
12 changed files with 9822 additions and 9118 deletions
+5 -1
View File
@@ -27,7 +27,11 @@ $end = $session->tribe * 10;
$level = (int)$village->resarray['f'.$id];
for ($i = $start; $i <= $end; $i++):
if ($i == 4 || $i == 23 || $i == 24) continue;
// FIX (triburi noi): Great Barracks antreneaza DOAR infanteria tribului, la
// fel ca Barracks-ul normal. Filtrul generic $unitsbytype['infantry'] acopera
// si triburile 6-9; vechea excludere 4/23/24 era hardcodata pentru triburile
// 1-5 si lasa cavaleria sa treaca la triburile noi.
if (!in_array($i, $unitsbytype['infantry'])) continue;
if (!($technology->getTech($i) || $i % 10 == 1)) continue;
$unit = ${'u'.$i};
+5 -1
View File
@@ -29,7 +29,11 @@ $horseDrinking = $building->getTypeLevel(41);
$success = 0;
for ($i = $start; $i <= $end; $i++):
if ($i == 3 || $i == 13 || $i == 14) continue;
// FIX (triburi noi): Great Stable antreneaza DOAR cavaleria tribului, la fel
// ca Stable-ul normal (20_train.tpl). Filtrul generic $unitsbytype['cavalry']
// acopera si triburile 6-9; vechea excludere 3/13/14 lasa sa treaca toate
// unitatile (infanterie, berbeci, catapulte).
if (!in_array($i, $unitsbytype['cavalry'])) continue;
if (!$technology->getTech($i)) continue;
$success++;