diff options
author | Andrei Karas <akaras@inbox.ru> | 2016-06-12 17:13:38 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2016-06-12 17:13:38 +0300 |
commit | 2390d257d3bd8efcdec33e318fd5d87fbea140a4 (patch) | |
tree | a8bb62a09b30f605570cafe3023c616fbc94a566 /src/emap/script_buildins.c | |
parent | ac815f32696c415f02c6c5cde1d10c3111d3d28e (diff) | |
download | plugin-2390d257d3bd8efcdec33e318fd5d87fbea140a4.tar.gz plugin-2390d257d3bd8efcdec33e318fd5d87fbea140a4.tar.bz2 plugin-2390d257d3bd8efcdec33e318fd5d87fbea140a4.tar.xz plugin-2390d257d3bd8efcdec33e318fd5d87fbea140a4.zip |
From script function npcwalkto return status code about is moving possible or not.
false mean error happend.
true mean moving is working.
Diffstat (limited to 'src/emap/script_buildins.c')
-rw-r--r-- | src/emap/script_buildins.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/emap/script_buildins.c b/src/emap/script_buildins.c index 809e091..e37026d 100644 --- a/src/emap/script_buildins.c +++ b/src/emap/script_buildins.c @@ -1427,16 +1427,16 @@ BUILDIN(npcWalkTo) status_calc_npc(nd, SCO_NONE); } nd->vd->dead_sit = 0; - unit->walktoxy(&nd->bl,x,y,0); + script_pushint(st, unit->walktoxy(&nd->bl,x,y,0)); + return true; } else { ShowWarning("npc not found\n"); script->reportsrc(st); + script_pushint(st, 0); return false; } - - return true; } BUILDIN(setBgTeam) |