fix: train blocks didn't reverse on direction change
Dieser Commit ist enthalten in:
Ursprung
8b221eea16
Commit
62c1321fc8
@ -62,6 +62,7 @@ Train::Train(World& world, std::string_view _id) :
|
||||
// update train direction from the block perspective:
|
||||
for(auto& status : *blocks)
|
||||
status->direction.setValueInternal(!status->direction.value());
|
||||
blocks.reverseInternal(); // index 0 is head of train
|
||||
|
||||
for(const auto& vehicle : m_poweredVehicles)
|
||||
vehicle->setDirection(value);
|
||||
@ -297,6 +298,7 @@ void Train::vehiclesChanged()
|
||||
updateWeight();
|
||||
updatePowered();
|
||||
updateSpeedMax();
|
||||
updateEnabled();
|
||||
}
|
||||
|
||||
void Train::updateLength()
|
||||
|
||||
Laden…
x
In neuem Issue referenzieren
Einen Benutzer sperren