diff --git a/mods/cnc/maps/funpark01/scj01ea.lua b/mods/cnc/maps/funpark01/scj01ea.lua index 25bea5fa4f11..5f0619b83ba9 100644 --- a/mods/cnc/maps/funpark01/scj01ea.lua +++ b/mods/cnc/maps/funpark01/scj01ea.lua @@ -13,8 +13,8 @@ BikeReinforcments = { "bike" } WorldLoaded = function() Nod = Player.GetPlayer("Nod") - dinosaur = Player.GetPlayer("Dinosaur") - civilian = Player.GetPlayer("Civilian") + Dinosaur = Player.GetPlayer("Dinosaur") + Civilian = Player.GetPlayer("Civilian") InvestigateObj = Nod.AddObjective("Investigate the nearby village for reports of\nstrange activity.") @@ -22,9 +22,9 @@ WorldLoaded = function() ReachVillageObj = Nod.AddObjective("Reach the village.") - Trigger.OnPlayerDiscovered(civilian, function(_, discoverer) + Trigger.OnPlayerDiscovered(Civilian, function(_, discoverer) if discoverer == Nod and not Nod.IsObjectiveCompleted(ReachVillageObj) then - if not dinosaur.HasNoRequiredUnits() then + if not Dinosaur.HasNoRequiredUnits() then KillDinos = Nod.AddObjective("Kill all creatures in the area.") end @@ -60,7 +60,7 @@ Tick = function() Nod.MarkFailedObjective(InvestigateObj) end - if dinosaur.HasNoRequiredUnits() then + if Dinosaur.HasNoRequiredUnits() then if KillDinos then Nod.MarkCompletedObjective(KillDinos) end Nod.MarkCompletedObjective(InvestigateObj) end diff --git a/mods/cnc/maps/gdi01/gdi01.lua b/mods/cnc/maps/gdi01/gdi01.lua index f07841d2464c..fdadd75cb5e4 100644 --- a/mods/cnc/maps/gdi01/gdi01.lua +++ b/mods/cnc/maps/gdi01/gdi01.lua @@ -32,8 +32,8 @@ WorldLoaded = function() InitObjectives(GDI) - secureAreaObjective = GDI.AddObjective("Eliminate all Nod forces in the area.") - beachheadObjective = GDI.AddObjective("Establish a beachhead.", "Secondary", false) + SecureAreaObjective = GDI.AddObjective("Eliminate all Nod forces in the area.") + BeachheadObjective = GDI.AddObjective("Establish a beachhead.", "Secondary", false) ReinforceWithLandingCraft(GDI, MCVReinforcements, lstStart.Location + CVec.New(2, 0), lstEnd.Location + CVec.New(2, 0), mcvTarget.Location) Reinforce(InfantryReinforcements) @@ -46,15 +46,15 @@ end Tick = function() if Nod.HasNoRequiredUnits() then - GDI.MarkCompletedObjective(secureAreaObjective) + GDI.MarkCompletedObjective(SecureAreaObjective) end if DateTime.GameTime > DateTime.Seconds(5) and GDI.HasNoRequiredUnits() then - GDI.MarkFailedObjective(beachheadObjective) - GDI.MarkFailedObjective(secureAreaObjective) + GDI.MarkFailedObjective(BeachheadObjective) + GDI.MarkFailedObjective(SecureAreaObjective) end - if DateTime.GameTime % DateTime.Seconds(1) == 0 and not GDI.IsObjectiveCompleted(beachheadObjective) and CheckForBase(GDI, GDIBaseBuildings) then - GDI.MarkCompletedObjective(beachheadObjective) + if DateTime.GameTime % DateTime.Seconds(1) == 0 and not GDI.IsObjectiveCompleted(BeachheadObjective) and CheckForBase(GDI, GDIBaseBuildings) then + GDI.MarkCompletedObjective(BeachheadObjective) end end diff --git a/mods/cnc/maps/gdi02/gdi02.lua b/mods/cnc/maps/gdi02/gdi02.lua index b7402cdf9a7e..90038cfb91e4 100644 --- a/mods/cnc/maps/gdi02/gdi02.lua +++ b/mods/cnc/maps/gdi02/gdi02.lua @@ -7,7 +7,7 @@ information, see COPYING. ]] -nodInBaseTeam = { RushBuggy, RushRifle1, RushRifle2, RushRifle3 } +NodInBaseTeam = { RushBuggy, RushRifle1, RushRifle2, RushRifle3 } MobileConstructionVehicle = { "mcv" } EngineerReinforcements = { "e6", "e6", "e6" } VehicleReinforcements = { "jeep" } @@ -44,22 +44,22 @@ WorldLoaded = function() InitObjectives(GDI) - nodObjective = Nod.AddObjective("Destroy all GDI troops.") - gdiObjective1 = GDI.AddObjective("Eliminate all Nod forces in the area.") - gdiObjective2 = GDI.AddObjective("Capture the Tiberium refinery.", "Secondary", false) + NodObjective = Nod.AddObjective("Destroy all GDI troops.") + GDIObjective1 = GDI.AddObjective("Eliminate all Nod forces in the area.") + GDIObjective2 = GDI.AddObjective("Capture the Tiberium refinery.", "Secondary", false) - Trigger.OnCapture(NodRefinery, function() GDI.MarkCompletedObjective(gdiObjective2) end) - Trigger.OnKilled(NodRefinery, function() GDI.MarkFailedObjective(gdiObjective2) end) + Trigger.OnCapture(NodRefinery, function() GDI.MarkCompletedObjective(GDIObjective2) end) + Trigger.OnKilled(NodRefinery, function() GDI.MarkFailedObjective(GDIObjective2) end) - Trigger.OnAllKilled(nodInBaseTeam, BridgeheadSecured) + Trigger.OnAllKilled(NodInBaseTeam, BridgeheadSecured) end Tick = function() if GDI.HasNoRequiredUnits() then - Nod.MarkCompletedObjective(nodObjective) + Nod.MarkCompletedObjective(NodObjective) end if Nod.HasNoRequiredUnits() then - GDI.MarkCompletedObjective(gdiObjective1) + GDI.MarkCompletedObjective(GDIObjective1) end end diff --git a/mods/cnc/maps/gdi04a/gdi04a.lua b/mods/cnc/maps/gdi04a/gdi04a.lua index 4ef977ef6021..90cf251293cb 100644 --- a/mods/cnc/maps/gdi04a/gdi04a.lua +++ b/mods/cnc/maps/gdi04a/gdi04a.lua @@ -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 diff --git a/mods/cnc/maps/gdi04b/gdi04b.lua b/mods/cnc/maps/gdi04b/gdi04b.lua index 0903760a03ee..23cb0a24e05b 100644 --- a/mods/cnc/maps/gdi04b/gdi04b.lua +++ b/mods/cnc/maps/gdi04b/gdi04b.lua @@ -110,16 +110,16 @@ WorldLoaded = function() SetupWorld() Trigger.OnExitedFootprint(BhndTrigger, function(a, id) - if not bhndTrigger and a.Owner == GDI then - bhndTrigger = true + if not BhndTriggered and a.Owner == GDI then + BhndTriggered = true Trigger.RemoveFootprintTrigger(id) SendHeli(NodHeli) end end) Trigger.OnExitedFootprint(Atk1Trigger, function(a, id) - if not atk1Trigger and a.Owner == GDI then - atk1Trigger = true + if not Atk1Triggered and a.Owner == GDI then + Atk1Triggered = true Trigger.RemoveFootprintTrigger(id) Build(NodxUnits, false, function(actor) @@ -131,8 +131,8 @@ WorldLoaded = function() end) Trigger.OnEnteredFootprint(Atk2Trigger, function(a, id) - if not atk2Trigger and a.Owner == GDI then - atk2Trigger = true + if not Atk2Triggered and a.Owner == GDI then + Atk2Triggered = true Trigger.RemoveFootprintTrigger(id) Build(NodxUnits, false, function(actor) @@ -144,8 +144,8 @@ 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) Build(AutoUnits, true, function(actor) @@ -153,15 +153,15 @@ WorldLoaded = function() IdleHunt(actor) end) - Trigger.AfterDelay(DateTime.Seconds(4), function() + Trigger.AfterDelay(DateTime.Seconds(4), function(tank) IdleHunt(tank) end) 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, { HeliEntry.Location, GDIHeliLZ.Location }) end diff --git a/mods/cnc/maps/gdi04c/gdi04c.lua b/mods/cnc/maps/gdi04c/gdi04c.lua index 23dbc58e7e6d..78978585a65b 100644 --- a/mods/cnc/maps/gdi04c/gdi04c.lua +++ b/mods/cnc/maps/gdi04c/gdi04c.lua @@ -16,7 +16,6 @@ GDIReinforcementsPart2 = { "e2", "e2", "e2", "e2", "e2" } TownAttackWave1 = { "bggy", "bggy" } TownAttackWave2 = { "ltnk", "ltnk" } TownAttackWave3 = { "e1", "e1", "e1", "e3", "e3", "e3" } -TownAttackWpts = { waypoint1, waypoint2 } Civvie1Wpts = { CivvieWpts1, CivvieWpts2 } Civvie2Wpts = { CivvieWpts3, CivvieWpts1, CivvieWpts4, CivvieWpts5, CivvieWpts6, CivvieWpts7, CivvieWpts8, CivvieWpts9, CivvieWpts10, CivvieWpts11 } @@ -41,7 +40,6 @@ end TownAttackAction = function(actor) Trigger.OnIdle(actor, TownAttackersIdleAction) - FollowWaypoints(actor, TownAttackWpts) end AttackTown = function() @@ -80,16 +78,16 @@ WorldLoaded = function() EliminateNod = GDI.AddPrimaryObjective("Eliminate all Nod forces in the area.") Trigger.OnExitedFootprint(TownAttackTrigger, function(a, id) - if not townAttackTrigger and a.Owner == GDI then - townAttackTrigger = true + if not TownAttackTriggered and a.Owner == GDI then + TownAttackTriggered = true Trigger.RemoveFootprintTrigger(id) AttackTown() end end) Trigger.OnEnteredFootprint(GDIReinforcementsTrigger, function(a, id) - if not gdiReinforcementsTrigger and a.Owner == GDI then - gdiReinforcementsTrigger = true + if not GDIReinforcementsTriggered and a.Owner == GDI then + GDIReinforcementsTriggered = true Trigger.RemoveFootprintTrigger(id) SendGDIReinforcements() end diff --git a/mods/cnc/maps/gdi07/gdi07.lua b/mods/cnc/maps/gdi07/gdi07.lua index b7ae17a927d3..6e1f8967c445 100644 --- a/mods/cnc/maps/gdi07/gdi07.lua +++ b/mods/cnc/maps/gdi07/gdi07.lua @@ -38,7 +38,7 @@ end AttackPlayer = function() Trigger.AfterDelay(DateTime.Seconds(40), function() for type, count in pairs({ ['e3'] = 3, ['e4'] = 2 }) do - atk1Actors = Utils.Take(count, Nod.GetActorsByType(type)) + local atk1Actors = Utils.Take(count, Nod.GetActorsByType(type)) Utils.Do(atk1Actors, function(unit) unit.Move(waypoint6.Location) unit.Move(waypoint7.Location) @@ -52,7 +52,7 @@ AttackPlayer = function() Trigger.AfterDelay(DateTime.Seconds(40), function() for type, count in pairs({ ['e1'] = 3, ['e3'] = 2 }) do - atk2Actors = Utils.Take(count, Nod.GetActorsByType(type)) + local atk2Actors = Utils.Take(count, Nod.GetActorsByType(type)) Utils.Do(atk2Actors, function(unit) unit.Move(waypoint11.Location) unit.Move(waypoint12.Location) @@ -65,7 +65,7 @@ AttackPlayer = function() Trigger.AfterDelay(DateTime.Seconds(80), function() for type, count in pairs({ ['e3'] = 3, ['e4'] = 2 }) do - atk3Actors = Utils.Take(count, Nod.GetActorsByType(type)) + local atk3Actors = Utils.Take(count, Nod.GetActorsByType(type)) Utils.Do(atk3Actors, function(unit) unit.Move(waypoint6.Location) unit.Move(waypoint7.Location) @@ -79,7 +79,7 @@ AttackPlayer = function() Trigger.AfterDelay(DateTime.Seconds(80), function() for type, count in pairs({ ['e1'] = 3, ['e3'] = 2 }) do - atk4Actors = Utils.Take(count, Nod.GetActorsByType(type)) + local atk4Actors = Utils.Take(count, Nod.GetActorsByType(type)) Utils.Do(atk4Actors, function(unit) unit.Move(waypoint11.Location) unit.Move(waypoint12.Location) @@ -91,7 +91,7 @@ AttackPlayer = function() end) Trigger.AfterDelay(DateTime.Seconds(80), function() - atk5Actors = Utils.Take(2, Nod.GetActorsByType('bggy')) + local atk5Actors = Utils.Take(2, Nod.GetActorsByType('bggy')) Utils.Do(atk5Actors, function(unit) unit.Move(waypoint11.Location) unit.Move(waypoint12.Location) diff --git a/mods/cnc/maps/gdi08a/gdi08a-AI.lua b/mods/cnc/maps/gdi08a/gdi08a-AI.lua index 1f49602acb4e..1074c6f7082f 100644 --- a/mods/cnc/maps/gdi08a/gdi08a-AI.lua +++ b/mods/cnc/maps/gdi08a/gdi08a-AI.lua @@ -91,10 +91,10 @@ GuardBase = function() end ProduceHarvester = function(building) - if not buildingHarvester then - buildingHarvester = true + if not BuildingHarvester then + BuildingHarvester = true building.Build(HarvesterProductionType, function() - buildingHarvester = false + BuildingHarvester = false end) end end diff --git a/mods/cnc/maps/gdi08b/gdi08b-AI.lua b/mods/cnc/maps/gdi08b/gdi08b-AI.lua index 4b6b06ff9ea0..0b2fc68b1837 100644 --- a/mods/cnc/maps/gdi08b/gdi08b-AI.lua +++ b/mods/cnc/maps/gdi08b/gdi08b-AI.lua @@ -94,10 +94,10 @@ ProduceHarvester = function(building) if building.IsDead or building.Owner ~= Nod then return end - if not buildingHarvester then - buildingHarvester = true + if not BuildingHarvester then + BuildingHarvester = true building.Build(HarvesterProductionType, function() - buildingHarvester = false + BuildingHarvester = false end) end end @@ -158,7 +158,6 @@ ProduceVehicle = function(building) VehicleAttackGroup[#VehicleAttackGroup + 1] = unit[1] if #VehicleAttackGroup >= VehicleGroupSize[Difficulty] then - MoveAndHunt(VehicleAttackGroup, Path) VehicleAttackGroup = { } Trigger.AfterDelay(VehicleProductionCooldown[Difficulty], function() ProduceArty(building) end) diff --git a/mods/cnc/maps/gdi08b/gdi08b.lua b/mods/cnc/maps/gdi08b/gdi08b.lua index 83bcff7f0500..8adb3571cbcd 100644 --- a/mods/cnc/maps/gdi08b/gdi08b.lua +++ b/mods/cnc/maps/gdi08b/gdi08b.lua @@ -72,7 +72,7 @@ SendWaves = function(counter, Waves) end SendHeli = function(heli) - units = Reinforcements.ReinforceWithTransport(Nod, "tran", heli.types, heli.entry, { heli.entry[1] }) + local units = Reinforcements.ReinforceWithTransport(Nod, "tran", heli.types, heli.entry, { heli.entry[1] }) Utils.Do(units[2], function(actor) actor.Hunt() Trigger.OnIdle(actor, actor.Hunt) @@ -84,12 +84,12 @@ SendHeli = function(heli) end MoveInitialArty = function(arty, waypoints) - units = { arty } + local units = { arty } MoveAndIdle(units, waypoints) end TankTerror = function(tank) - units = { tank } + local units = { tank } MoveAndHunt(units, WaypointGroupVillageLeft) end diff --git a/mods/cnc/maps/gdi09/gdi09-AI.lua b/mods/cnc/maps/gdi09/gdi09-AI.lua index 9a03e408484c..cac53388a6be 100644 --- a/mods/cnc/maps/gdi09/gdi09-AI.lua +++ b/mods/cnc/maps/gdi09/gdi09-AI.lua @@ -90,10 +90,10 @@ GuardBase = function() end ProduceHarvester = function(building) - if not buildingHarvester then - buildingHarvester = true + if not BuildingHarvester then + BuildingHarvester = true building.Build(HarvesterProductionType, function() - buildingHarvester = false + BuildingHarvester = false end) end end diff --git a/mods/cnc/maps/nod07a/nod07a-AI.lua b/mods/cnc/maps/nod07a/nod07a-AI.lua index a61730e939ca..00c582479545 100644 --- a/mods/cnc/maps/nod07a/nod07a-AI.lua +++ b/mods/cnc/maps/nod07a/nod07a-AI.lua @@ -68,10 +68,10 @@ CheckForHarvester = function() end ProduceHarvester = function(building) - if not buildingHarvester then - buildingHarvester = true + if not BuildingHarvester then + BuildingHarvester = true building.Build(HarvesterProductionType, function() - buildingHarvester = false + BuildingHarvester = false end) end end diff --git a/mods/cnc/maps/nod07a/nod07a.lua b/mods/cnc/maps/nod07a/nod07a.lua index 3bc94b9e10c5..8a5e103f7b9c 100644 --- a/mods/cnc/maps/nod07a/nod07a.lua +++ b/mods/cnc/maps/nod07a/nod07a.lua @@ -119,8 +119,8 @@ SendReinforcementsWave = function(team) end Trigger.OnEnteredFootprint(AbandonedBaseTrigger, function(a, id) - if not abandonedBaseTrigger and a.Owner == Nod then - abandonedBaseTrigger = true + if not AbandonedBaseTriggered and a.Owner == Nod then + AbandonedBaseTriggered = true Trigger.RemoveFootprintTrigger(id) FlareCamera = Actor.Create("camera", true, { Owner = Nod, Location = waypoint25.Location }) @@ -141,8 +141,8 @@ Trigger.OnEnteredFootprint(AbandonedBaseTrigger, function(a, id) end) Trigger.OnEnteredFootprint(ReinforcementsTrigger, function(a, id) - if not reinforcementsTrigger and a.Owner == Nod and a.Type ~= "harv" then - reinforcementsTrigger = true + if not ReinforcementsTriggered and a.Owner == Nod and a.Type ~= "harv" then + ReinforcementsTriggered = true Trigger.RemoveFootprintTrigger(id) Trigger.AfterDelay(DateTime.Seconds(5), function() diff --git a/mods/cnc/maps/nod07b/nod07b-AI.lua b/mods/cnc/maps/nod07b/nod07b-AI.lua index ab40cbe96c82..b63d337a3041 100644 --- a/mods/cnc/maps/nod07b/nod07b-AI.lua +++ b/mods/cnc/maps/nod07b/nod07b-AI.lua @@ -68,10 +68,10 @@ CheckForHarvester = function() end ProduceHarvester = function(building) - if not buildingHarvester then - buildingHarvester = true + if not BuildingHarvester then + BuildingHarvester = true building.Build(HarvesterProductionType, function() - buildingHarvester = false + BuildingHarvester = false end) end end @@ -139,23 +139,23 @@ Trigger.OnAllKilledOrCaptured(GDIBase, function() Utils.Do(GDI.GetGroundAttackers(), IdleHunt) end) -Trigger.OnKilled(GDIProc, function(building) +Trigger.OnKilled(GDIProc, function() BuildBuilding(BaseProc, GDICYard) end) -Trigger.OnKilled(GDINuke1, function(building) +Trigger.OnKilled(GDINuke1, function() BuildBuilding(BaseNuke1, GDICYard) end) -Trigger.OnKilled(GDINuke2, function(building) +Trigger.OnKilled(GDINuke2, function() BuildBuilding(BaseNuke2, GDICYard) end) -Trigger.OnKilled(GDINuke3, function(building) +Trigger.OnKilled(GDINuke3, function() BuildBuilding(BaseNuke3, GDICYard) end) -Trigger.OnKilled(GDIPyle, function(building) +Trigger.OnKilled(GDIPyle, function() BuildBuilding(InfantryProduction, GDICYard) end) diff --git a/mods/cnc/maps/nod07b/nod07b.lua b/mods/cnc/maps/nod07b/nod07b.lua index e4c32e347308..47556454e2c9 100644 --- a/mods/cnc/maps/nod07b/nod07b.lua +++ b/mods/cnc/maps/nod07b/nod07b.lua @@ -121,32 +121,32 @@ SendReinforcementsWave = function(team) end Trigger.OnEnteredFootprint(Atk1, function(a, id) - if not atk1Trigger and a.Owner == Nod then - atk1Trigger = true + if not Atk1Triggered and a.Owner == Nod then + Atk1Triggered = true SendAttackWave(GDI5) Trigger.RemoveFootprintTrigger(id) end end) Trigger.OnEnteredFootprint(Atk2, function(a, id) - if not atk2Trigger and a.Owner == Nod then - atk2Trigger = true + if not Atk2Triggered and a.Owner == Nod then + Atk2Triggered = true SendAttackWave(GDI4) Trigger.RemoveFootprintTrigger(id) end end) Trigger.OnEnteredFootprint(Atk3, function(a, id) - if not atk3Trigger and a.Owner == Nod then - atk3Trigger = true + if not Atk3Triggered and a.Owner == Nod then + Atk3Triggered = true SendAttackWave(GDI6) Trigger.RemoveFootprintTrigger(id) end end) Trigger.OnEnteredFootprint(Atk4, function(a, id) - if not atk4Trigger and a.Owner == Nod then - atk4Trigger = true + if not Atk4Triggered and a.Owner == Nod then + Atk4Triggered = true SendReinforcementsWave(GDI1) Trigger.RemoveFootprintTrigger(id) end diff --git a/mods/cnc/maps/nod08a/nod08a-AI.lua b/mods/cnc/maps/nod08a/nod08a-AI.lua index 6c032a69e2b8..f71d5cb0a892 100644 --- a/mods/cnc/maps/nod08a/nod08a-AI.lua +++ b/mods/cnc/maps/nod08a/nod08a-AI.lua @@ -89,10 +89,10 @@ GuardBase = function() end ProduceHarvester = function(building) - if not buildingHarvester then - buildingHarvester = true + if not BuildingHarvester then + BuildingHarvester = true building.Build(HarvesterProductionType, function() - buildingHarvester = false + BuildingHarvester = false end) end end @@ -158,27 +158,27 @@ Trigger.OnAllKilledOrCaptured(GDIBase, function() Utils.Do(GDI.GetGroundAttackers(), IdleHunt) end) -Trigger.OnKilled(GDIProc, function(building) +Trigger.OnKilled(GDIProc, function() BuildBuilding(BaseProc, GDICYard) end) -Trigger.OnKilled(GDINuke1, function(building) +Trigger.OnKilled(GDINuke1, function() BuildBuilding(BaseNuke1, GDICYard) end) -Trigger.OnKilled(GDINuke2, function(building) +Trigger.OnKilled(GDINuke2, function() BuildBuilding(BaseNuke2, GDICYard) end) -Trigger.OnKilled(GDINuke3, function(building) +Trigger.OnKilled(GDINuke3, function() BuildBuilding(BaseNuke3, GDICYard) end) -Trigger.OnKilled(GDINuke4, function(building) +Trigger.OnKilled(GDINuke4, function() BuildBuilding(BaseNuke4, GDICYard) end) -Trigger.OnKilled(GDIPyle, function(building) +Trigger.OnKilled(GDIPyle, function() BuildBuilding(InfantryProduction, GDICYard) end) diff --git a/mods/cnc/maps/nod08b/nod08b-AI.lua b/mods/cnc/maps/nod08b/nod08b-AI.lua index 603d53a2702d..1dcfc58d38a9 100644 --- a/mods/cnc/maps/nod08b/nod08b-AI.lua +++ b/mods/cnc/maps/nod08b/nod08b-AI.lua @@ -89,10 +89,10 @@ GuardBase = function() end ProduceHarvester = function(building) - if not buildingHarvester then - buildingHarvester = true + if not BuildingHarvester then + BuildingHarvester = true building.Build(HarvesterProductionType, function() - buildingHarvester = false + BuildingHarvester = false end) end end @@ -158,30 +158,30 @@ Trigger.OnAllKilledOrCaptured(GDIBase, function() Utils.Do(GDI.GetGroundAttackers(), IdleHunt) end) -Trigger.OnKilled(GDIProc, function(building) +Trigger.OnKilled(GDIProc, function() BuildBuilding(BaseProc, GDICYard) end) -Trigger.OnKilled(GDINuke1, function(building) +Trigger.OnKilled(GDINuke1, function() BuildBuilding(BaseNuke1, GDICYard) end) -Trigger.OnKilled(GDINuke2, function(building) +Trigger.OnKilled(GDINuke2, function() BuildBuilding(BaseNuke2, GDICYard) end) -Trigger.OnKilled(GDINuke3, function(building) +Trigger.OnKilled(GDINuke3, function() BuildBuilding(BaseNuke3, GDICYard) end) -Trigger.OnKilled(GDINuke4, function(building) +Trigger.OnKilled(GDINuke4, function() BuildBuilding(BaseNuke4, GDICYard) end) -Trigger.OnKilled(GDIPyle, function(building) +Trigger.OnKilled(GDIPyle, function() BuildBuilding(InfantryProduction, GDICYard) end) -Trigger.OnKilled(GDIWeap, function(building) +Trigger.OnKilled(GDIWeap, function() BuildBuilding(VehicleProduction, GDICYard) end) diff --git a/mods/cnc/maps/nod09/nod09-AI.lua b/mods/cnc/maps/nod09/nod09-AI.lua index 2ed49cbc4d96..7eb54e1738e3 100644 --- a/mods/cnc/maps/nod09/nod09-AI.lua +++ b/mods/cnc/maps/nod09/nod09-AI.lua @@ -93,10 +93,10 @@ GuardBase = function() end ProduceHarvester = function(building) - if not buildingHarvester then - buildingHarvester = true + if not BuildingHarvester then + BuildingHarvester = true building.Build(HarvesterProductionType, function() - buildingHarvester = false + BuildingHarvester = false end) end end @@ -162,30 +162,30 @@ Trigger.OnAllKilledOrCaptured(GDIBase, function() Utils.Do(GDI.GetGroundAttackers(), IdleHunt) end) -Trigger.OnKilled(GDIProc, function(building) +Trigger.OnKilled(GDIProc, function() BuildBuilding(BaseProc, GDICYard) end) -Trigger.OnKilled(GDINuke1, function(building) +Trigger.OnKilled(GDINuke1, function() BuildBuilding(BaseNuke1, GDICYard) end) -Trigger.OnKilled(GDINuke2, function(building) +Trigger.OnKilled(GDINuke2, function() BuildBuilding(BaseNuke2, GDICYard) end) -Trigger.OnKilled(GDINuke3, function(building) +Trigger.OnKilled(GDINuke3, function() BuildBuilding(BaseNuke3, GDICYard) end) -Trigger.OnKilled(GDINuke4, function(building) +Trigger.OnKilled(GDINuke4, function() BuildBuilding(BaseNuke4, GDICYard) end) -Trigger.OnKilled(GDIPyle, function(building) +Trigger.OnKilled(GDIPyle, function() BuildBuilding(InfantryProduction, GDICYard) end) -Trigger.OnKilled(GDIWeap, function(building) +Trigger.OnKilled(GDIWeap, function() BuildBuilding(VehicleProduction, GDICYard) end)