(svn r13953) -Add [YAPP]: Free track reservations of crashed trains. (michi_cc)

This commit is contained in:
rubidium
2008-08-02 22:54:07 +00:00
parent 10d8fb6456
commit d06fb949ff
2 changed files with 25 additions and 1 deletions

View File

@@ -887,7 +887,10 @@ static void FloodVehicle(Vehicle *v)
switch (v->type) {
default: NOT_REACHED();
case VEH_TRAIN:
if (IsFrontEngine(v)) pass += 4; // driver
if (IsFrontEngine(v)) {
pass += 4; // driver
FreeTrainTrackReservation(v);
}
v->u.rail.crash_anim_pos = 4000; // max 4440, disappear pretty fast
InvalidateWindowClassesData(WC_TRAINS_LIST, 0);
break;