Fixed decay-rate for trained units.

This commit is contained in:
johns 2002-11-28 21:13:01 +00:00
parent 4c576de23c
commit 71cdb547f6

View file

@ -114,7 +114,9 @@ global void HandleActionTrain(Unit* unit)
DropOutOnSide(nunit,LookingW,type->TileWidth,type->TileHeight);
// set life span
nunit->TTL=GameCycle+type->DecayRate*6*CYCLES_PER_SECOND;
if( type->DecayRate ) {
nunit->TTL=GameCycle+type->DecayRate*6*CYCLES_PER_SECOND;
}
// FIXME: GameMessage
if( player==ThisPlayer ) {