From 534b7d425fcd6f0ab86e77b8404e09685a64d204 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sat, 3 Oct 2015 00:49:58 +0300 Subject: Add variable '.walkmask' for get/set npc walk mask. --- src/emap/script.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/src/emap/script.c b/src/emap/script.c index 2939c1e..9e37f7a 100644 --- a/src/emap/script.c +++ b/src/emap/script.c @@ -138,6 +138,12 @@ void eset_reg_npcscope_num(struct script_state* st, struct reg_db *n, int64 *num clif->sitting(&nd->bl); hookStop(); } + else if (!strcmp(name, ".walkmask")) + { + getExt(); + ext->walkMask = *val; + hookStop(); + } } int eget_val_npcscope_num(struct script_state* st, struct reg_db *n, struct script_data* data) @@ -146,7 +152,6 @@ int eget_val_npcscope_num(struct script_state* st, struct reg_db *n, struct scri if (!strcmp(name, ".lang")) { getExtRet(0); - hookStop(); return ext->language; } @@ -210,6 +215,12 @@ int eget_val_npcscope_num(struct script_state* st, struct reg_db *n, struct scri hookStop(); return nd->vd->dead_sit == 0 ? 1 : 0; } + else if (!strcmp(name, ".walkmask")) + { + getExtRet(0); + hookStop(); + return ext->walkMask; + } return 0; } -- cgit v1.2.3-70-g09d2