summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoseph Botosh <rumly111@gmail.com>2015-10-27 17:39:54 +0200
committerJoseph Botosh <rumly111@gmail.com>2015-10-27 17:39:54 +0200
commite11491050fc496ed956d6f54720a39954efac37f (patch)
treed437c99db3974c976814554a1d6a2601a4b7f9db
parent02efd5eb257b200001299c51988f21b47aab96a6 (diff)
downloadserverdata-e11491050fc496ed956d6f54720a39954efac37f.tar.gz
serverdata-e11491050fc496ed956d6f54720a39954efac37f.tar.bz2
serverdata-e11491050fc496ed956d6f54720a39954efac37f.tar.xz
serverdata-e11491050fc496ed956d6f54720a39954efac37f.zip
fix getrandompoint function
-rw-r--r--npc/functions/npcmovegraph.txt4
1 files changed, 2 insertions, 2 deletions
diff --git a/npc/functions/npcmovegraph.txt b/npc/functions/npcmovegraph.txt
index 284c8c19..5629736c 100644
--- a/npc/functions/npcmovegraph.txt
+++ b/npc/functions/npcmovegraph.txt
@@ -227,7 +227,7 @@ function script getnextmovecmd {
function script getrandompoint {
if (getargcount() < 4)
{
- debugmes "error: getrandompoint(x, y, w, h) takes 4 arguments";
+ debugmes "error: getrandompoint(x1, y1, x2, y2) takes 4 arguments";
return -1;
}
@@ -244,7 +244,7 @@ function script getrandompoint {
for (.@poke = 0; .@poke < .@max_pokes; .@poke++)
{
.@rx = rand(.@x1, .@x2);
- .@ry = rand(.@y2, .@y2);
+ .@ry = rand(.@y1, .@y2);
if (checknpccell(.@map$, .@rx, .@ry, cell_chkpass))
goto L_Found;
}