summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2024-06-30 12:01:59 -0300
committerJesusaves <cpntb1@ymail.com>2024-06-30 12:01:59 -0300
commit77e0e7eace50e539950ed242d9aa65d0e25609f2 (patch)
tree8d9278e2a1007a090f49b806bd00532b23585492
parentdbdc81278ab6821c038c57285d6df0b6d83b8fc2 (diff)
downloadserverdata-77e0e7eace50e539950ed242d9aa65d0e25609f2.tar.gz
serverdata-77e0e7eace50e539950ed242d9aa65d0e25609f2.tar.bz2
serverdata-77e0e7eace50e539950ed242d9aa65d0e25609f2.tar.xz
serverdata-77e0e7eace50e539950ed242d9aa65d0e25609f2.zip
Minor guards
-rw-r--r--npc/005-5/nylo.txt2
-rw-r--r--npc/magic/mpregen.txt6
2 files changed, 7 insertions, 1 deletions
diff --git a/npc/005-5/nylo.txt b/npc/005-5/nylo.txt
index 338614040..c43ee652d 100644
--- a/npc/005-5/nylo.txt
+++ b/npc/005-5/nylo.txt
@@ -19,7 +19,7 @@
select
l("Yeah, you're right."),
l("You store a large collection of goods. Could you perhaps sell me some?"),
- rif(!.@q,l("What do you for a living?")),
+ rif(!.@q, l("What do you do for a living?")),
rif(.@q && .@q2 < gettimetick(2),l("Can I help you again?")),
l("What is banking?");
switch (@menu)
diff --git a/npc/magic/mpregen.txt b/npc/magic/mpregen.txt
index dc8ad2bd3..7bbd4e471 100644
--- a/npc/magic/mpregen.txt
+++ b/npc/magic/mpregen.txt
@@ -21,11 +21,17 @@ function script SK_mpregen {
}
function script SK_transfermp {
+ if (!playerattached()) return;
.@mp = Sp;
.@me = getcharid(3);
.@tg = getarg(0, @skillTarget);
detachrid();
attachrid(.@tg);
+ if (!playerattached()) {
+ attachrid(.@me);
+ dispbottom l("Specified target does not exist. An error happened.");
+ return;
+ }
.@mo = MaxSp - Sp;
// Heal will be the smallest from:
// Current MP or Missing Mp