From dd84b2285be464ccb04f3435a0b9855da79ecee5 Mon Sep 17 00:00:00 2001 From: johns <> Date: Sun, 10 Mar 2002 04:40:20 +0000 Subject: [PATCH] Fixed another bug in rescueing units. --- src/unit/unit.cpp | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/src/unit/unit.cpp b/src/unit/unit.cpp index cda56c028..9b477aa72 100644 --- a/src/unit/unit.cpp +++ b/src/unit/unit.cpp @@ -708,6 +708,7 @@ global void UnitLost(Unit* unit) unit->SavedOrder.Goal=NoUnitP; } unit->Orders[0].Action=UnitActionStill; + unit->SubAction=unit->State=0; DebugCheck( player->NumFoodUnits > UnitMax); DebugCheck( player->NumBuildings > UnitMax); @@ -1398,15 +1399,6 @@ global void ChangeUnitOwner(Unit* unit,Player* oldplayer,Player* newplayer) // UnitLost(unit); -#if 0 - // Remove from old player table - - temp=oldplayer->Units[--oldplayer->TotalNumUnits]; - temp->PlayerSlot=unit->PlayerSlot; - *unit->PlayerSlot=temp; - oldplayer->Units[oldplayer->TotalNumUnits]=NULL; -#endif - // // Now the new side! //