Commit 8d23739338d3959dfbfc6a071edcc1ec72c30921

Authored by Nagyhal
1 parent 987ccf56

Fix Rune: Biting Gale not being used by tactical AI

This was caused by the lack of a "radius" attribute.

Which tactical.lua makes good use of the talent's "target" value, for
the initial range check it ignores this and uses the sum of
getTalentRadius and getTalentRange. So, while Biting Gale had a
perfectly good target table, because the radius was not stored in a
separate radius value the AI was assuming it to have a range of 0 and
thus never using it.

I've searched through the entire code base, and not found any other
cases exactly like this. I have, however, found a few which could be
mildly improved. I'll consider uploading a bundle of such fixes later.
... ... @@ -685,8 +685,9 @@ newInscription{
685 685 end },
686 686 requires_target = true,
687 687 range = 0,
  688 + radius = 6,
688 689 target = function(self, t)
689   - return {type="cone", cone_angle=25, radius = 6, range=self:getTalentRange(t), talent=t, display={particle="bolt_ice", trail="icetrail"}}
  690 + return {type="cone", cone_angle=25, radius = self:getTalentRadius(t), range=self:getTalentRange(t), talent=t, display={particle="bolt_ice", trail="icetrail"}}
690 691 end,
691 692 action = function(self, t)
692 693 local data = self:getInscriptionData(t.short_name)
... ...