From eac20fd1f784099f5f680b122a4a773cb6467851 Mon Sep 17 00:00:00 2001 From: Jesusaves Date: Sat, 11 Jul 2020 01:16:56 -0300 Subject: This hotfix might fix a potential glitch while using First Aid >.< Should not solve anything, but should address an edge case scenario --- npc/config/magic.txt | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'npc/config') diff --git a/npc/config/magic.txt b/npc/config/magic.txt index c0c639e26..87f804df2 100644 --- a/npc/config/magic.txt +++ b/npc/config/magic.txt @@ -20,6 +20,10 @@ function script AdjustSpellpower { .@type=getarg(2, HARM_MAGI); .@src=getcharid(3); + // Prevents a possible glitch, unoptimal fix + if (.@target < 1) + .@target=getcharid(3); + .@dmg=calcdmg(.@src, .@target, .@type); // Abizit Influence (80%~130% at best, worst shot at perfect ctrl is 105%) .@dmg = .@dmg * (80 + abizit() * rand2(5,10)) / 100; -- cgit v1.2.3-60-g2f50