Commit 059645266b1b1262cca72b55c5a990005548267e

Authored by Chris Davidson
1 parent 1801f507

Remove friendly fire from talent procs

Players have no direct control over procs so having friendlyfire of any kind on them is very annoying.  Additionally this limits what talents you can use as procs at all because of said annoying behavior.

There may be some weird edge cases where the targeting isn't handled right but overall this should be the better default behavior.
... ... @@ -577,6 +577,8 @@ setDefaultProjector(function(src, x, y, type, dam, state)
577 577 end
578 578
579 579 if src.__projecting_for then
  580 + -- Disable friendly fire for procs since players can't control when they happen or where they hit
  581 + src.nullify_all_friendlyfire = 1
580 582 if src.talent_on_spell and next(src.talent_on_spell) and t.is_spell and not src.turn_procs.spell_talent then
581 583 for id, d in pairs(src.talent_on_spell) do
582 584 if rng.percent(d.chance) and t.id ~= d.talent then
... ... @@ -609,6 +611,7 @@ setDefaultProjector(function(src, x, y, type, dam, state)
609 611 end
610 612 end
611 613 end
  614 + src.nullify_all_friendlyfire = nil
612 615
613 616 if not target.dead and (t.is_spell or t.is_mind) and not src.turn_procs.meteoric_crash and src.knowTalent and src:knowTalent(src.T_METEORIC_CRASH) then
614 617 src.turn_procs.meteoric_crash = true
... ...