Fix reinforcements appearing in soviet04a/b despite killed radar dome
This commit is contained in:
@@ -31,6 +31,10 @@ AttackPaths =
|
|||||||
}
|
}
|
||||||
|
|
||||||
ReinfInf = function()
|
ReinfInf = function()
|
||||||
|
if Radar.IsDead or Radar.Owner ~= Greece then
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
Reinforcements.Reinforce(Greece, InfantryReinfGreece, InfReinfPath, 0, function(soldier)
|
Reinforcements.Reinforce(Greece, InfantryReinfGreece, InfReinfPath, 0, function(soldier)
|
||||||
soldier.Hunt()
|
soldier.Hunt()
|
||||||
end)
|
end)
|
||||||
@@ -46,35 +50,39 @@ ReinfArmor = function()
|
|||||||
end
|
end
|
||||||
|
|
||||||
BringPatrol1 = function()
|
BringPatrol1 = function()
|
||||||
|
if Radar.IsDead or Radar.Owner ~= Greece then
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
local units = Reinforcements.Reinforce(Greece, Patrol1Group, { SWRoadPoint.Location }, 0)
|
local units = Reinforcements.Reinforce(Greece, Patrol1Group, { SWRoadPoint.Location }, 0)
|
||||||
Utils.Do(units, function(patrols)
|
Utils.Do(units, function(patrols)
|
||||||
patrols.Patrol(Patrol1Path, true, 250)
|
patrols.Patrol(Patrol1Path, true, 250)
|
||||||
end)
|
end)
|
||||||
|
|
||||||
if not Radar.IsDead and Radar.Owner == Greece then
|
Trigger.OnAllKilled(units, function()
|
||||||
Trigger.OnAllKilled(units, function()
|
if Map.Difficulty == "Hard" then
|
||||||
if Map.Difficulty == "Hard" then
|
Trigger.AfterDelay(DateTime.Minutes(4), BringPatrol1)
|
||||||
Trigger.AfterDelay(DateTime.Minutes(4), BringPatrol1)
|
else
|
||||||
else
|
Trigger.AfterDelay(DateTime.Minutes(7), BringPatrol1)
|
||||||
Trigger.AfterDelay(DateTime.Minutes(7), BringPatrol1)
|
end
|
||||||
end
|
end)
|
||||||
end)
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|
||||||
BringPatrol2 = function()
|
BringPatrol2 = function()
|
||||||
|
if Radar.IsDead or Radar.Owner ~= Greece then
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
local units = Reinforcements.Reinforce(Greece, Patrol2Group, { NRoadPoint.Location }, 0)
|
local units = Reinforcements.Reinforce(Greece, Patrol2Group, { NRoadPoint.Location }, 0)
|
||||||
Utils.Do(units, function(patrols)
|
Utils.Do(units, function(patrols)
|
||||||
patrols.Patrol(Patrol2Path, true, 250)
|
patrols.Patrol(Patrol2Path, true, 250)
|
||||||
end)
|
end)
|
||||||
|
|
||||||
if not Radar.IsDead and Radar.Owner == Greece then
|
Trigger.OnAllKilled(units, function()
|
||||||
Trigger.OnAllKilled(units, function()
|
if Map.Difficulty == "Hard" then
|
||||||
if Map.Difficulty == "Hard" then
|
Trigger.AfterDelay(DateTime.Minutes(4), BringPatrol2)
|
||||||
Trigger.AfterDelay(DateTime.Minutes(4), BringPatrol2)
|
else
|
||||||
else
|
Trigger.AfterDelay(DateTime.Minutes(7), BringPatrol2)
|
||||||
Trigger.AfterDelay(DateTime.Minutes(7), BringPatrol2)
|
end
|
||||||
end
|
end)
|
||||||
end)
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -31,6 +31,10 @@ AttackPaths =
|
|||||||
}
|
}
|
||||||
|
|
||||||
ReinfInf = function()
|
ReinfInf = function()
|
||||||
|
if Radar.IsDead or Radar.Owner ~= Greece then
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
Reinforcements.Reinforce(Greece, InfantryReinfGreece, InfReinfPath, 0, function(soldier)
|
Reinforcements.Reinforce(Greece, InfantryReinfGreece, InfReinfPath, 0, function(soldier)
|
||||||
soldier.Hunt()
|
soldier.Hunt()
|
||||||
end)
|
end)
|
||||||
@@ -46,35 +50,39 @@ ReinfArmor = function()
|
|||||||
end
|
end
|
||||||
|
|
||||||
BringPatrol1 = function()
|
BringPatrol1 = function()
|
||||||
|
if Radar.IsDead or Radar.Owner ~= Greece then
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
local units = Reinforcements.Reinforce(Greece, Patrol1Group, { NRoadPoint.Location }, 0)
|
local units = Reinforcements.Reinforce(Greece, Patrol1Group, { NRoadPoint.Location }, 0)
|
||||||
Utils.Do(units, function(patrols)
|
Utils.Do(units, function(patrols)
|
||||||
patrols.Patrol(Patrol1Path, true, 250)
|
patrols.Patrol(Patrol1Path, true, 250)
|
||||||
end)
|
end)
|
||||||
|
|
||||||
if not Radar.IsDead and Radar.Owner == Greece then
|
Trigger.OnAllKilled(units, function()
|
||||||
Trigger.OnAllKilled(units, function()
|
if Map.Difficulty == "Hard" then
|
||||||
if Map.Difficulty == "Hard" then
|
Trigger.AfterDelay(DateTime.Minutes(4), BringPatrol1)
|
||||||
Trigger.AfterDelay(DateTime.Minutes(4), BringPatrol1)
|
else
|
||||||
else
|
Trigger.AfterDelay(DateTime.Minutes(7), BringPatrol1)
|
||||||
Trigger.AfterDelay(DateTime.Minutes(7), BringPatrol1)
|
end
|
||||||
end
|
end)
|
||||||
end)
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|
||||||
BringPatrol2 = function()
|
BringPatrol2 = function()
|
||||||
|
if Radar.IsDead or Radar.Owner ~= Greece then
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
local units = Reinforcements.Reinforce(Greece, Patrol2Group, { NRoadPoint.Location }, 0)
|
local units = Reinforcements.Reinforce(Greece, Patrol2Group, { NRoadPoint.Location }, 0)
|
||||||
Utils.Do(units, function(patrols)
|
Utils.Do(units, function(patrols)
|
||||||
patrols.Patrol(Patrol2Path, true, 250)
|
patrols.Patrol(Patrol2Path, true, 250)
|
||||||
end)
|
end)
|
||||||
|
|
||||||
if not Radar.IsDead and Radar.Owner == Greece then
|
Trigger.OnAllKilled(units, function()
|
||||||
Trigger.OnAllKilled(units, function()
|
if Map.Difficulty == "Hard" then
|
||||||
if Map.Difficulty == "Hard" then
|
Trigger.AfterDelay(DateTime.Minutes(4), BringPatrol2)
|
||||||
Trigger.AfterDelay(DateTime.Minutes(4), BringPatrol2)
|
else
|
||||||
else
|
Trigger.AfterDelay(DateTime.Minutes(7), BringPatrol2)
|
||||||
Trigger.AfterDelay(DateTime.Minutes(7), BringPatrol2)
|
end
|
||||||
end
|
end)
|
||||||
end)
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user