Code cleanup in the Tiberian Dawn Lua scripts.

Uppercase global variables.
Declare local variables.
Remove unused variable.
This commit is contained in:
Matthias Mailänder
2022-09-09 10:13:24 +02:00
committed by Gustas
parent ca45e02265
commit b8e261ff2f
18 changed files with 108 additions and 115 deletions

View File

@@ -122,16 +122,16 @@ WorldLoaded = function()
end)
Trigger.OnEnteredFootprint(AutoTrigger, function(a, id)
if not autoTrigger and a.Owner == GDI then
autoTrigger = true
if not AutoTriggered and a.Owner == GDI then
AutoTriggered = true
Trigger.RemoveFootprintTrigger(id)
BuildAuto()
end
end)
Trigger.OnEnteredFootprint(GDIHeliTrigger, function(a, id)
if not gdiHeliTrigger and a.Owner == GDI then
gdiHeliTrigger = true
if not GDIHeliTriggered and a.Owner == GDI then
GDIHeliTriggered = true
Trigger.RemoveFootprintTrigger(id)
Reinforcements.ReinforceWithTransport(GDI, "tran", nil, { GDIHeliEntry.Location, GDIHeliLZ.Location })
end