equal
deleted
inserted
replaced
2077 // bail out if not all wagons are in the same depot or not in a depot at all |
2077 // bail out if not all wagons are in the same depot or not in a depot at all |
2078 for (u = v; u != NULL; u = u->next) { |
2078 for (u = v; u != NULL; u = u->next) { |
2079 if (u->u.rail.track != 0x80 || u->tile != v->tile) return false; |
2079 if (u->u.rail.track != 0x80 || u->tile != v->tile) return false; |
2080 } |
2080 } |
2081 |
2081 |
|
2082 // if the train got no power, then keep it in the depot |
|
2083 if (v->u.rail.cached_power == 0) { |
|
2084 v->vehstatus |= VS_STOPPED; |
|
2085 InvalidateWindow(WC_VEHICLE_DEPOT, v->tile); |
|
2086 return true; |
|
2087 } |
|
2088 |
2082 if (v->u.rail.force_proceed == 0) { |
2089 if (v->u.rail.force_proceed == 0) { |
2083 if (++v->load_unload_time_rem < 37) { |
2090 if (++v->load_unload_time_rem < 37) { |
2084 InvalidateWindowClasses(WC_TRAINS_LIST); |
2091 InvalidateWindowClasses(WC_TRAINS_LIST); |
2085 return true; |
2092 return true; |
2086 } |
2093 } |