Codechange: Add support for additional command result values.

This commit is contained in:
Michael Lutz
2021-11-30 00:52:23 +01:00
parent 8503854655
commit 3e85e833a7
10 changed files with 136 additions and 41 deletions

View File

@@ -173,6 +173,16 @@ ScriptObject::ActiveInstance::~ActiveInstance()
return GetStorage()->last_command_res;
}
/* static */ void ScriptObject::SetLastCommandResData(CommandDataBuffer data)
{
GetStorage()->last_cmd_ret = std::move(data);
}
/* static */ const CommandDataBuffer &ScriptObject::GetLastCommandResData()
{
return GetStorage()->last_cmd_ret;
}
/* static */ void ScriptObject::SetNewVehicleID(VehicleID vehicle_id)
{
GetStorage()->new_vehicle_id = vehicle_id;