(svn r10363) -Fix [FS#911]: invalidating autoreplace windows didn't take account of vehicle group (Matthias Wolf)

This commit is contained in:
peter1138
2007-06-27 20:40:20 +00:00
parent b9db0b8cf1
commit 85fb4eb94b
8 changed files with 12 additions and 10 deletions

View File

@@ -677,7 +677,7 @@ void DestroyVehicle(Vehicle *v)
if (IsEngineCountable(v)) {
GetPlayer(v->owner)->num_engines[v->engine_type]--;
if (v->owner == _local_player) InvalidateAutoreplaceWindow(v->engine_type);
if (v->owner == _local_player) InvalidateAutoreplaceWindow(v->engine_type, v->group_id);
if (IsValidGroupID(v->group_id)) GetGroup(v->group_id)->num_engines[v->engine_type]--;
if (v->IsPrimaryVehicle()) DecreaseGroupNumVehicle(v->group_id);