summaryrefslogtreecommitdiff
path: root/npc
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2021-12-30 11:34:56 -0300
committerJesusaves <cpntb1@ymail.com>2021-12-30 11:34:56 -0300
commit176a8fc7c1699adeab6322429f7bb6b9351631a2 (patch)
treedbf5b08211bd4227d7a474e13a5ca1151cf66e4e /npc
parent930cccb7c211f065aaf241689487550353e29cfb (diff)
downloadserverdata-176a8fc7c1699adeab6322429f7bb6b9351631a2.tar.gz
serverdata-176a8fc7c1699adeab6322429f7bb6b9351631a2.tar.bz2
serverdata-176a8fc7c1699adeab6322429f7bb6b9351631a2.tar.xz
serverdata-176a8fc7c1699adeab6322429f7bb6b9351631a2.zip
Fix or polish some minor stuff after testing, up to homun 6004
Diffstat (limited to 'npc')
-rw-r--r--npc/functions/hub.txt11
1 files changed, 7 insertions, 4 deletions
diff --git a/npc/functions/hub.txt b/npc/functions/hub.txt
index 9d5cdfeaf..51d4bf707 100644
--- a/npc/functions/hub.txt
+++ b/npc/functions/hub.txt
@@ -389,11 +389,14 @@ function script HUB_SkillInvoke {
sc_start SC_CURSE, rand2(3500, 5000), 1, 10000, SCFLAG_NONE, @skillCaster;
break;
case TMW2_CAPRICE:
- .@gid = @skillCaster; // gethominfo(0);
- .@ak1 = getunitdata(.@gid, UDT_MATKMIN);
- .@ak2 = getunitdata(.@gid, UDT_MATKMAX);
+ .@gid = @skillCaster;
+ .@ak1 = max(getunitdata(.@gid, UDT_MATKMIN), getunitdata(.@gid, UDT_INT));
+ .@ak2 = max(getunitdata(.@gid, UDT_MATKMAX), .@ak1 * 12 / 10);
+ /* FIXME: Validate if mob is still alive after each hit */
for (.@i=0; .@i < limit(1, @skillLv, 10); .@i++) {
- harm(@skillTarget, rand2(.@ak1, .@ak2), HARM_MAGI, any(Ele_Fire, Ele_Water, Ele_Wind, Ele_Earth), .@gid);
+ .@dmg=rand2(.@ak1, .@ak2);
+ .@ele=any(Ele_Fire, Ele_Water, Ele_Wind, Ele_Earth);
+ harm(@skillTarget, .@dmg, HARM_MAGI, .@ele, .@gid);
sleep2(100);
}
break;