Fix some more whitespace/formatting issues.

This commit is contained in:
Jonathan G Rennison
2016-01-31 15:22:46 +00:00
parent 5e924262f4
commit 9742300a1e
5 changed files with 17 additions and 18 deletions

View File

@@ -171,7 +171,6 @@ int GroundVehicle<T, Type>::GetAcceleration()
AccelStatus mode = v->GetAccelerationStatus();
/* handle breakdown power reduction */
//TODO
if (Type == VEH_TRAIN && mode == AS_ACCEL && HasBit(Train::From(this)->flags, VRF_BREAKDOWN_POWER)) {
/* We'd like to cache this, but changing cached_power has too many unwanted side-effects */
uint32 power_temp;
@@ -246,7 +245,6 @@ int GroundVehicle<T, Type>::GetAcceleration()
accel -= this->acceleration >> 1;
}
if (this->IsFrontEngine() && !(this->current_order_time & 0x1FF) &&
!(this->current_order.IsType(OT_LOADING)) &&
!(Train::From(this)->flags & (VRF_IS_BROKEN | (1 << VRF_TRAIN_STUCK))) &&

View File

@@ -384,9 +384,10 @@ protected:
}
}
}
if(this->breakdown_type == BREAKDOWN_LOW_SPEED)
if (this->breakdown_type == BREAKDOWN_LOW_SPEED) {
tempmax = min(max_speed, this->breakdown_severity);
}
}
if (this->cur_speed > max_speed) {
tempmax = max(this->cur_speed - (this->cur_speed / 10) - 1, max_speed);