(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

@@ -14,7 +14,6 @@
#include "script_station.hpp"
#include "script_cargo.hpp"
#include "../../station_base.h"
#include "../../company_func.h"
#include "../../script/squirrel_helper_type.hpp"
/* static */ ScriptRoad::RoadVehicleType ScriptRoad::GetRoadVehicleTypeForCargo(CargoID cargo_type)
@@ -54,7 +53,7 @@
/* static */ bool ScriptRoad::IsRoadTypeAvailable(RoadType road_type)
{
return ::HasRoadTypesAvail(_current_company, ::RoadTypeToRoadTypes((::RoadType)road_type));
return ::HasRoadTypesAvail(ScriptObject::GetCompany(), ::RoadTypeToRoadTypes((::RoadType)road_type));
}
/* static */ ScriptRoad::RoadType ScriptRoad::GetCurrentRoadType()