diff options
author | Michael Lutz <michi@icosahedron.de> | 2021-11-05 23:55:23 +0100 |
---|---|---|
committer | Michael Lutz <michi@icosahedron.de> | 2021-12-16 22:28:32 +0100 |
commit | 21675ec7e22bfe53f20300cc27b4d50c84aeb4dc (patch) | |
tree | bfc6a1ef650ac6def3b80f86ec8d1a424900f459 /src/script/api/script_engine.cpp | |
parent | 2637c06f88ed6f9dea55449883f42a62c30f19d8 (diff) | |
download | openttd-21675ec7e22bfe53f20300cc27b4d50c84aeb4dc.tar.xz |
Codechange: Un-bitstuff vehicle/engine commands.
Diffstat (limited to 'src/script/api/script_engine.cpp')
-rw-r--r-- | src/script/api/script_engine.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/script/api/script_engine.cpp b/src/script/api/script_engine.cpp index d6cab36b6..7530693d0 100644 --- a/src/script/api/script_engine.cpp +++ b/src/script/api/script_engine.cpp @@ -286,7 +286,7 @@ EnforcePrecondition(false, IsValidEngine(engine_id)); EnforcePrecondition(false, company != ScriptCompany::COMPANY_INVALID); - return ScriptObject::Command<CMD_ENGINE_CTRL>::Do(0, engine_id, (uint32)company | (1 << 31), {}); + return ScriptObject::Command<CMD_ENGINE_CTRL>::Do(engine_id, (::CompanyID)company, true); } /* static */ bool ScriptEngine::DisableForCompany(EngineID engine_id, ScriptCompany::CompanyID company) @@ -297,5 +297,5 @@ EnforcePrecondition(false, IsValidEngine(engine_id)); EnforcePrecondition(false, company != ScriptCompany::COMPANY_INVALID); - return ScriptObject::Command<CMD_ENGINE_CTRL>::Do(0, engine_id, company, {}); + return ScriptObject::Command<CMD_ENGINE_CTRL>::Do(engine_id, (::CompanyID)company, false); } |