(svn r23632) -Add: GSCompanyMode, to change company in GameScripts

This commit is contained in:
truebrain
2011-12-19 21:05:25 +00:00
parent 867b263900
commit 95b199e313
46 changed files with 273 additions and 59 deletions

View File

@@ -178,7 +178,7 @@
{
if (!IsValidTown(town_id)) return false;
return ::HasBit(::Town::Get(town_id)->statues, _current_company);
return ::HasBit(::Town::Get(town_id)->statues, ScriptObject::GetCompany());
}
/* static */ bool ScriptTown::IsCity(TownID town_id)
@@ -213,7 +213,7 @@
{
if (!IsValidTown(town_id)) return false;
return HasBit(::GetMaskOfTownActions(NULL, _current_company, ::Town::Get(town_id)), town_action);
return HasBit(::GetMaskOfTownActions(NULL, ScriptObject::GetCompany(), ::Town::Get(town_id)), town_action);
}
/* static */ bool ScriptTown::PerformTownAction(TownID town_id, TownAction town_action)