summaryrefslogtreecommitdiff
path: root/src/map/script.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/map/script.c')
-rw-r--r--src/map/script.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/map/script.c b/src/map/script.c
index 0fba00dd5..39552a441 100644
--- a/src/map/script.c
+++ b/src/map/script.c
@@ -11282,7 +11282,9 @@ BUILDIN(getunits)
if (not_server_variable(*name)) {
sd = script->rid2sd(st);
+
if (sd == NULL) {
+ script_pushint(st, 0);
return true; // player variable but no player attached
}
}
@@ -18157,7 +18159,7 @@ BUILDIN(setpcblock)
if ((type & PCBLOCK_IMMUNE) != 0)
sd->block_action.immune = state;
- if ((type & PCBLOCK_SITSTAND) != 0)
+ if ((type & PCBLOCK_SITSTAND) != 0)
sd->block_action.sitstand = state;
if ((type & PCBLOCK_COMMANDS) != 0)
@@ -24190,7 +24192,9 @@ BUILDIN(openstylist)
if (sd == NULL)
return false;
- clif->open_ui(sd, STYLIST_UI);
+#if PACKETVER >= 20150128
+ clif->open_ui(sd, CZ_STYLIST_UI);
+#endif
return true;
}
@@ -25285,7 +25289,7 @@ void script_hardcoded_constants(void)
script->set_constant("MST_AROUND3", MST_AROUND3, false, false);
script->set_constant("MST_AROUND4", MST_AROUND4, false, false);
script->set_constant("MST_AROUND", MST_AROUND , false, false);
-
+
script->constdb_comment("pc block constants, use with *setpcblock* and *checkpcblock*");
script->set_constant("PCBLOCK_NONE", PCBLOCK_NONE, false, false);
script->set_constant("PCBLOCK_MOVE", PCBLOCK_MOVE, false, false);