* Get the next real (non-articulated part and non rear part of dualheaded engine) vehicle in the consist. * @return Next vehicle in the consist. */
| 148 | * @return Next vehicle in the consist. |
| 149 | */ |
| 150 | inline Train *GetNextUnit() const |
| 151 | { |
| 152 | Train *v = this->GetNextVehicle(); |
| 153 | if (v != nullptr && v->IsRearDualheaded()) v = v->GetNextVehicle(); |
| 154 | |
| 155 | return v; |
| 156 | } |
| 157 | |
| 158 | /** |
| 159 | * Get the previous real (non-articulated part and non rear part of dualheaded engine) vehicle in the consist. |
no test coverage detected