diff --git a/src/script/api/script_subsidy.cpp b/src/script/api/script_subsidy.cpp index 7e90f8e9a2..0372f315cb 100644 --- a/src/script/api/script_subsidy.cpp +++ b/src/script/api/script_subsidy.cpp @@ -31,7 +31,7 @@ return ::Subsidy::Get(subsidy_id)->IsAwarded(); } -/* static */ bool ScriptSubsidy::Create(CargoID cargo_type, SubsidyParticipantType from_type, uint16 from_id, SubsidyParticipantType to_type, uint16 to_id) +/* static */ bool ScriptSubsidy::Create(CargoID cargo_type, SubsidyParticipantType from_type, SQInteger from_id, SubsidyParticipantType to_type, SQInteger to_id) { EnforcePrecondition(false, ScriptCargo::IsValidCargo(cargo_type)); EnforcePrecondition(false, from_type == SPT_INDUSTRY || from_type == SPT_TOWN); @@ -78,7 +78,7 @@ return (SubsidyParticipantType)(uint)::Subsidy::Get(subsidy_id)->src_type; } -/* static */ int32 ScriptSubsidy::GetSourceIndex(SubsidyID subsidy_id) +/* static */ SQInteger ScriptSubsidy::GetSourceIndex(SubsidyID subsidy_id) { if (!IsValidSubsidy(subsidy_id)) return INVALID_SOURCE; @@ -92,7 +92,7 @@ return (SubsidyParticipantType)(uint)::Subsidy::Get(subsidy_id)->dst_type; } -/* static */ int32 ScriptSubsidy::GetDestinationIndex(SubsidyID subsidy_id) +/* static */ SQInteger ScriptSubsidy::GetDestinationIndex(SubsidyID subsidy_id) { if (!IsValidSubsidy(subsidy_id)) return INVALID_SOURCE; diff --git a/src/script/api/script_subsidy.hpp b/src/script/api/script_subsidy.hpp index a4f9fa6867..b59d8bb591 100644 --- a/src/script/api/script_subsidy.hpp +++ b/src/script/api/script_subsidy.hpp @@ -62,7 +62,7 @@ public: * @pre (to_type == SPT_INDUSTRY && ScriptIndustry::IsValidIndustry(to_id)) || (to_type == SPT_TOWN && ScriptTown::IsValidTown(to_id)) * @api -ai */ - static bool Create(CargoID cargo_type, SubsidyParticipantType from_type, uint16 from_id, SubsidyParticipantType to_type, uint16 to_id); + static bool Create(CargoID cargo_type, SubsidyParticipantType from_type, SQInteger from_id, SubsidyParticipantType to_type, SQInteger to_id); /** * Get the company index of the company this subsidy is awarded to. @@ -109,7 +109,7 @@ public: * @pre IsValidSubsidy(subsidy_id). * @return One of TownID/IndustryID. */ - static int32 GetSourceIndex(SubsidyID subsidy_id); + static SQInteger GetSourceIndex(SubsidyID subsidy_id); /** * Returns the type of destination of subsidy. @@ -127,7 +127,7 @@ public: * @pre IsValidSubsidy(subsidy_id). * @return One of TownID/IndustryID. */ - static int32 GetDestinationIndex(SubsidyID subsidy_id); + static SQInteger GetDestinationIndex(SubsidyID subsidy_id); }; #endif /* SCRIPT_SUBSIDY_HPP */