Fix the campaign AI defending captured buildings
This commit is contained in:
@@ -122,6 +122,9 @@ end
|
|||||||
|
|
||||||
DefendActor = function(unit, defendingPlayer, defenderCount)
|
DefendActor = function(unit, defendingPlayer, defenderCount)
|
||||||
Trigger.OnDamaged(unit, function(self, attacker)
|
Trigger.OnDamaged(unit, function(self, attacker)
|
||||||
|
if unit.Owner ~= defendingPlayer then
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
-- Don't try to attack spiceblooms
|
-- Don't try to attack spiceblooms
|
||||||
if attacker and attacker.Type == "spicebloom" then
|
if attacker and attacker.Type == "spicebloom" then
|
||||||
|
|||||||
Reference in New Issue
Block a user