Merge pull request #6794 from abcdefg30/mtmfix
Fixed broken triggers on monster-tank-madness
This commit is contained in:
@@ -1530,7 +1530,7 @@ Actors:
|
|||||||
Location: 32,56
|
Location: 32,56
|
||||||
Owner: BadGuy
|
Owner: BadGuy
|
||||||
Health: 0.6875
|
Health: 0.6875
|
||||||
Actor479: silo
|
USSROutpostSilo: silo
|
||||||
Location: 37,61
|
Location: 37,61
|
||||||
Owner: BadGuy
|
Owner: BadGuy
|
||||||
Actor480: powr
|
Actor480: powr
|
||||||
|
|||||||
@@ -76,17 +76,19 @@ SetupAlliedBase = function()
|
|||||||
Utils.Do(SuperTanks, function(tnk)
|
Utils.Do(SuperTanks, function(tnk)
|
||||||
if not tnk.IsDead then
|
if not tnk.IsDead then
|
||||||
Trigger.ClearAll(tnk)
|
Trigger.ClearAll(tnk)
|
||||||
Trigger.OnIdle(tnk, function()
|
Trigger.AfterDelay(0, function()
|
||||||
if SuperTankAttack then
|
Trigger.OnIdle(tnk, function()
|
||||||
if tnk.Location == SuperTankMoveWaypoints[SuperTankMove].Location then
|
if SuperTankAttack then
|
||||||
SuperTankMove = SuperTankMove + 1
|
if tnk.Location == SuperTankMoveWaypoints[SuperTankMove].Location then
|
||||||
if SuperTankMove == 5 then
|
SuperTankMove = SuperTankMove + 1
|
||||||
SuperTankAttack = false
|
if SuperTankMove == 5 then
|
||||||
|
SuperTankAttack = false
|
||||||
|
end
|
||||||
|
else
|
||||||
|
tnk.AttackMove(SuperTankMoveWaypoints[SuperTankMove].Location, 2)
|
||||||
end
|
end
|
||||||
else
|
|
||||||
tnk.AttackMove(SuperTankMoveWaypoints[SuperTankMove].Location, 2)
|
|
||||||
end
|
end
|
||||||
end
|
end)
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
end)
|
end)
|
||||||
@@ -123,19 +125,21 @@ SuperTankDomeInfiltrated = function()
|
|||||||
SuperTankHunt = 4
|
SuperTankHunt = 4
|
||||||
SuperTankHuntCounter = -1
|
SuperTankHuntCounter = -1
|
||||||
end
|
end
|
||||||
Trigger.OnIdle(tnk, function()
|
Trigger.AfterDelay(0, function()
|
||||||
if SuperTankAttack then
|
Trigger.OnIdle(tnk, function()
|
||||||
if tnk.Location == SuperTankHuntWaypoints[SuperTankHunt].Location then
|
if SuperTankAttack then
|
||||||
SuperTankHunt = SuperTankHunt + SuperTankHuntCounter
|
if tnk.Location == SuperTankHuntWaypoints[SuperTankHunt].Location then
|
||||||
if SuperTankHunt == 0 or SuperTankHunt == 5 then
|
SuperTankHunt = SuperTankHunt + SuperTankHuntCounter
|
||||||
SuperTankAttack = false
|
if SuperTankHunt == 0 or SuperTankHunt == 5 then
|
||||||
|
SuperTankAttack = false
|
||||||
|
end
|
||||||
|
else
|
||||||
|
tnk.AttackMove(SuperTankHuntWaypoints[SuperTankHunt].Location, 2)
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
tnk.AttackMove(SuperTankHuntWaypoints[SuperTankHunt].Location, 2)
|
tnk.Hunt()
|
||||||
end
|
end
|
||||||
else
|
end)
|
||||||
tnk.Hunt()
|
|
||||||
end
|
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
end)
|
end)
|
||||||
@@ -228,8 +232,8 @@ InitPlayers = function()
|
|||||||
|
|
||||||
player.Cash = 0
|
player.Cash = 0
|
||||||
ussr.Cash = 2000
|
ussr.Cash = 2000
|
||||||
--badguy.Resources = badguy.ResourceCapacity -- doesn't work, workaround below
|
Trigger.AfterDelay(0, function() badguy.Resources = badguy.ResourceCapacity * 0.75 end)
|
||||||
Trigger.OnCapture(Actor479, function()
|
Trigger.OnCapture(USSROutpostSilo, function() -- getting money through capturing doesn't work
|
||||||
player.Cash = player.Cash + Utils.RandomInteger(1200, 1300)
|
player.Cash = player.Cash + Utils.RandomInteger(1200, 1300)
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user