Change: Units-system can convert from N to kN, don't preconvert.
This allows force to passed as is and avoid premature rounding. The AI function "GetMaxTractiveEffort" still needs to return kN to avoid breaking the API.
This commit is contained in:

committed by
Michael Lutz

parent
e2f583a34f
commit
bf9caa425b
@@ -172,7 +172,7 @@
|
||||
if (GetVehicleType(engine_id) != ScriptVehicle::VT_RAIL && GetVehicleType(engine_id) != ScriptVehicle::VT_ROAD) return -1;
|
||||
if (IsWagon(engine_id)) return -1;
|
||||
|
||||
return ::Engine::Get(engine_id)->GetDisplayMaxTractiveEffort();
|
||||
return ::Engine::Get(engine_id)->GetDisplayMaxTractiveEffort() / 1000;
|
||||
}
|
||||
|
||||
/* static */ ScriptDate::Date ScriptEngine::GetDesignDate(EngineID engine_id)
|
||||
|
Reference in New Issue
Block a user