From 5b34c8019f135afd9f20d043a489ab96f286038a Mon Sep 17 00:00:00 2001 From: Charles Pigott Date: Mon, 22 Apr 2019 09:10:04 +0100 Subject: Codechange: Remove Company/OwnerByte types --- src/script/api/script_cargomonitor.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/script/api/script_cargomonitor.cpp') diff --git a/src/script/api/script_cargomonitor.cpp b/src/script/api/script_cargomonitor.cpp index 3cb9b4a8e..e862fed3e 100644 --- a/src/script/api/script_cargomonitor.cpp +++ b/src/script/api/script_cargomonitor.cpp @@ -20,7 +20,7 @@ /* static */ int32 ScriptCargoMonitor::GetTownDeliveryAmount(ScriptCompany::CompanyID company, CargoID cargo, TownID town_id, bool keep_monitoring) { CompanyID cid = static_cast(company); - if (cid < OWNER_BEGIN || cid >= MAX_COMPANIES) return -1; + if (cid >= MAX_COMPANIES) return -1; if (!ScriptCargo::IsValidCargo(cargo)) return -1; if (!::Town::IsValidID(town_id)) return -1; @@ -31,7 +31,7 @@ /* static */ int32 ScriptCargoMonitor::GetIndustryDeliveryAmount(ScriptCompany::CompanyID company, CargoID cargo, IndustryID industry_id, bool keep_monitoring) { CompanyID cid = static_cast(company); - if (cid < OWNER_BEGIN || cid >= MAX_COMPANIES) return -1; + if (cid >= MAX_COMPANIES) return -1; if (!ScriptCargo::IsValidCargo(cargo)) return -1; if (!::Industry::IsValidID(industry_id)) return -1; @@ -42,7 +42,7 @@ /* static */ int32 ScriptCargoMonitor::GetTownPickupAmount(ScriptCompany::CompanyID company, CargoID cargo, TownID town_id, bool keep_monitoring) { CompanyID cid = static_cast(company); - if (cid < OWNER_BEGIN || cid >= MAX_COMPANIES) return -1; + if (cid >= MAX_COMPANIES) return -1; if (!ScriptCargo::IsValidCargo(cargo)) return -1; if (!::Town::IsValidID(town_id)) return -1; @@ -53,7 +53,7 @@ /* static */ int32 ScriptCargoMonitor::GetIndustryPickupAmount(ScriptCompany::CompanyID company, CargoID cargo, IndustryID industry_id, bool keep_monitoring) { CompanyID cid = static_cast(company); - if (cid < OWNER_BEGIN || cid >= MAX_COMPANIES) return -1; + if (cid >= MAX_COMPANIES) return -1; if (!ScriptCargo::IsValidCargo(cargo)) return -1; if (!::Industry::IsValidID(industry_id)) return -1; -- cgit v1.2.3-54-g00ecf