Commit 3af6b414c6d1f44b3511c9c4cfc153a4c976d963
1 parent
624a6732
Hook "Combat:archeryFire" now also received a "target" parameter, with the coord…
…inates of the targeted square
Showing
1 changed file
with
1 additions
and
1 deletions
... | ... | @@ -722,7 +722,7 @@ function _M:archeryShoot(targets, talent, tg, params, force) |
722 | 722 | print("[ARCHERY SHOOT dofire] Shooting weapon:", realweapon and realweapon.name, "to:", targets[i].x, targets[i].y) |
723 | 723 | if realweapon.on_archery_trigger then realweapon.on_archery_trigger(realweapon, self, tg, params, targets[i], talent) end -- resources must be handled by the weapon function |
724 | 724 | -- hook to trigger as each archery projectile is created |
725 | - local hd = {"Combat:archeryFire", tg=tg, archery = tg.archery, weapon=weapon, realweapon = realweapon, ammo=ammo} | |
725 | + local hd = {"Combat:archeryFire", tg=tg, archery = tg.archery, weapon=weapon, realweapon = realweapon, ammo=ammo, target={x=targets[i].x, y=targets[i].y}} | |
726 | 726 | self:triggerHook(hd) |
727 | 727 | local proj = self:projectile(tg, targets[i].x, targets[i].y, archery_projectile) |
728 | 728 | end | ... | ... |
-
Please register or login to post a comment