Skip to content

Commit

Permalink
fix strats scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
Strogoo authored and shalkya committed Sep 22, 2019
1 parent a080a9d commit a89d3ed
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion units/UAA0304/UAA0304_Script.lua
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ UAA0304 = Class(AAirUnit) {
},

OnDamage = function(self, instigator, amount, vector, damageType)
if instigator:GetBlueprint().CategoriesHash.STRATEGICBOMBER and instigator:GetArmy() == self:GetArmy() then
if instigator and instigator:GetBlueprint().CategoriesHash.STRATEGICBOMBER and instigator:GetArmy() == self:GetArmy() then
return
end

Expand Down
2 changes: 1 addition & 1 deletion units/UEA0304/UEA0304_Script.lua
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ UEA0304 = Class(TAirUnit) {
},

OnDamage = function(self, instigator, amount, vector, damageType)
if instigator:GetBlueprint().CategoriesHash.STRATEGICBOMBER and instigator:GetArmy() == self:GetArmy() then
if instigator and instigator:GetBlueprint().CategoriesHash.STRATEGICBOMBER and instigator:GetArmy() == self:GetArmy() then
return
end

Expand Down
2 changes: 1 addition & 1 deletion units/URA0304/URA0304_Script.lua
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ URA0304 = Class(CAirUnit) {
end,

OnDamage = function(self, instigator, amount, vector, damageType)
if instigator:GetBlueprint().CategoriesHash.STRATEGICBOMBER and instigator:GetArmy() == self:GetArmy() then
if instigator and instigator:GetBlueprint().CategoriesHash.STRATEGICBOMBER and instigator:GetArmy() == self:GetArmy() then
return
end

Expand Down
2 changes: 1 addition & 1 deletion units/XSA0304/XSA0304_Script.lua
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ XSA0304 = Class(SAirUnit) {
},

OnDamage = function(self, instigator, amount, vector, damageType)
if instigator:GetBlueprint().CategoriesHash.STRATEGICBOMBER and instigator:GetArmy() == self:GetArmy() then
if instigator and instigator:GetBlueprint().CategoriesHash.STRATEGICBOMBER and instigator:GetArmy() == self:GetArmy() then
return
end

Expand Down

0 comments on commit a89d3ed

Please sign in to comment.