From f778b511c7c30b8a9332c4d920d3c458f63c070d Mon Sep 17 00:00:00 2001 From: mekolat Date: Sat, 30 Apr 2016 18:57:58 -0400 Subject: add line_of_sight check to `ingrav` spell --- world/map/npc/magic/level2-lightning-strike.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/world/map/npc/magic/level2-lightning-strike.txt b/world/map/npc/magic/level2-lightning-strike.txt index cf30a627..b7e2319c 100644 --- a/world/map/npc/magic/level2-lightning-strike.txt +++ b/world/map/npc/magic/level2-lightning-strike.txt @@ -24,7 +24,7 @@ goto L_FreeRecast; OnAttack: - if (target(BL_ID, @target_id, 22) != 22) goto L_FreeRecast; // 0x10 | 0x02 | 0x04 + if (target(BL_ID, @target_id, 0x36) != 0x36) goto L_FreeRecast; // 0x10 | 0x02 | 0x04 | 0x20 set .@p, get(.max_radius, "rain") + 1; set @ingravspell[5], @target_id; // store it because foreach overwrites it -- cgit v1.2.3-60-g2f50 From 2120bf7eb41dab7b856324c7b6eb5e657c79feca Mon Sep 17 00:00:00 2001 From: mekolat Date: Sat, 30 Apr 2016 19:38:29 -0400 Subject: check line of sight in `itenplz` spell --- world/map/npc/magic/level1-aggravate.txt | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/world/map/npc/magic/level1-aggravate.txt b/world/map/npc/magic/level1-aggravate.txt index 05474a2a..bad64e02 100644 --- a/world/map/npc/magic/level1-aggravate.txt +++ b/world/map/npc/magic/level1-aggravate.txt @@ -10,7 +10,13 @@ set Sp, Sp - 3; misceffect FX_MAGIC_GREEN, strcharinfo(0); callfunc "magic_exp"; - aggravate getmap(), (POS_X - @distance), (POS_Y - @distance), (POS_X + @distance), (POS_Y + @distance), SFX_DEFAULT; + foreach 2, getmap(), (POS_X - @distance), (POS_Y - @distance), (POS_X + @distance), (POS_Y + @distance), strnpcinfo(0) + "::OnMob"; + end; + +OnMob: + if (target(BL_ID, @target_id, 0x20) != 0x20) end; // line of sight + aggravate @target_id; + misceffect SFX_DEFAULT, @target_id; end; OnInit: -- cgit v1.2.3-60-g2f50