Update Spawn.lua (#2149)

Small fix
This commit is contained in:
Thomas 2024-07-16 08:45:37 +02:00 committed by GitHub
parent 214cd3748c
commit 5d6951ae11
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -3934,7 +3934,7 @@ function SPAWN:_OnDeadOrCrash( EventData )
if EventPrefix then -- EventPrefix can be nil if no # is found, which means, no spawnable group!
self:T( { "Dead event: " .. EventPrefix } )
self:T(string.format("EventPrefix = %s | SpawnAliasPrefix = %s | Old AliveUnits = %d",EventPrefix,self.SpawnAliasPrefix,self.AliveUnits))
self:T(string.format("EventPrefix = %s | SpawnAliasPrefix = %s | Old AliveUnits = %d",EventPrefix or "",self.SpawnAliasPrefix or "",self.AliveUnits or 0))
if EventPrefix == self.SpawnTemplatePrefix or ( self.SpawnAliasPrefix and EventPrefix == self.SpawnAliasPrefix ) and self.AliveUnits > 0 then
self.AliveUnits = self.AliveUnits - 1
end