(svn r18812) -Codechange: make some functions in train.h functions of Train.

This commit is contained in:
rubidium
2010-01-15 18:23:52 +00:00
parent 55d1db5b28
commit aaf0b4b46c
10 changed files with 84 additions and 80 deletions

View File

@@ -700,7 +700,7 @@ static bool UpdateConsists(int32 p1)
Train *t;
FOR_ALL_TRAINS(t) {
/* Update the consist of all trains so the maximum speed is set correctly. */
if (t->IsFrontEngine() || t->IsFreeWagon()) TrainConsistChanged(t, true);
if (t->IsFrontEngine() || t->IsFreeWagon()) t->ConsistChanged(true);
}
return true;
}
@@ -737,8 +737,8 @@ static bool TrainAccelerationModelChanged(int32 p1)
Train *t;
FOR_ALL_TRAINS(t) {
if (t->IsFrontEngine()) {
t->tcache.cached_max_curve_speed = GetTrainCurveSpeedLimit(t);
UpdateTrainAcceleration(t);
t->tcache.cached_max_curve_speed = t->GetCurveSpeedLimit();
t->UpdateAcceleration();
}
}