summaryrefslogtreecommitdiff
path: root/npc/magic/config.txt
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2021-04-15 14:45:36 -0300
committerJesusaves <cpntb1@ymail.com>2021-04-15 14:45:36 -0300
commit67543201d8646c059b3928d14c2591c02168237a (patch)
treefca28d81e39f5bcbf313dca3542af0aafd945483 /npc/magic/config.txt
parent827a9f2be696ece2984776fcc77ebd1439db9032 (diff)
downloadserverdata-67543201d8646c059b3928d14c2591c02168237a.tar.gz
serverdata-67543201d8646c059b3928d14c2591c02168237a.tar.bz2
serverdata-67543201d8646c059b3928d14c2591c02168237a.tar.xz
serverdata-67543201d8646c059b3928d14c2591c02168237a.zip
Joyplim, Frillyar and Kalmurk
Diffstat (limited to 'npc/magic/config.txt')
-rw-r--r--npc/magic/config.txt5
1 files changed, 3 insertions, 2 deletions
diff --git a/npc/magic/config.txt b/npc/magic/config.txt
index 2cede16a..a179982c 100644
--- a/npc/magic/config.txt
+++ b/npc/magic/config.txt
@@ -160,13 +160,14 @@ function script SK_summon {
.@amt=getarg(1);
.@mex=getarg(2, 1);
.@sum=getarg(3, true);
+ .@lvl=getskilllv(SKILL_MAGIC);
if ($@GM_OVERRIDE || debug) debugmes "Skill "+@skillId+" Lv "+@skillLv;
- if (ispcdead())
+ if (ispcdead() || !.@lvl || !@skillLv)
return;
if (rand2(10) < abizit()) {
// Summon Magic (with magic level bonus)
- SummonMagic(@skillId, .@mob, .@amt, MAGIC_LVL+@skillLv-1, @skillLv, .@sum);
+ SummonMagic(@skillId, .@mob, .@amt, .@lvl+@skillLv-1, @skillLv, .@sum);
} else if (rand2(10) < abizit()) {
// Re-roll
dispbottom l("You cannot complete the casting correctly!");