Changeset View
Changeset View
Standalone View
Standalone View
binaries/data/mods/public/gui/structree/structree.js
Show First 20 Lines • Show All 253 Lines • ▼ Show 20 Lines | if (g_ParsedData.units[unitCode] && g_ParsedData.units[unitCode].production && Object.keys(g_ParsedData.units[unitCode].production).length) | ||||
g_ParsedData.units[unitCode].production.techs.splice( | g_ParsedData.units[unitCode].production.techs.splice( | ||||
g_ParsedData.units[unitCode].production.techs.indexOf(prod), | g_ParsedData.units[unitCode].production.techs.indexOf(prod), | ||||
1, ...techPairs[prod].techs | 1, ...techPairs[prod].techs | ||||
); | ); | ||||
trainerList.push(unitCode); | trainerList.push(unitCode); | ||||
} | } | ||||
g_CivData[g_SelectedCiv].relicCart = loadUnit("other/catafalque/"+g_SelectedCiv+"_catafalque"); | |||||
g_CivData[g_SelectedCiv].buildList = buildList; | g_CivData[g_SelectedCiv].buildList = buildList; | ||||
g_CivData[g_SelectedCiv].trainList = trainerList; | g_CivData[g_SelectedCiv].trainList = trainerList; | ||||
draw(); | draw(); | ||||
drawPhaseIcons(); | drawPhaseIcons(); | ||||
} | } | ||||
function closeStrucTree() | function closeStrucTree() | ||||
{ | { | ||||
if (g_CallbackSet) | if (g_CallbackSet) | ||||
Engine.PopGuiPageCB(0); | Engine.PopGuiPageCB(0); | ||||
else | else | ||||
Engine.PopGuiPage(); | Engine.PopGuiPage(); | ||||
} | } |
Wildfire Games · Phabricator