diff options
author | Andrei Karas <akaras@inbox.ru> | 2015-05-02 19:22:31 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2015-05-02 19:24:53 +0300 |
commit | e5534b4202c5b68d6b0fd0e2f01fae073aa7c8e7 (patch) | |
tree | b90dc0943c241568d4072875d59ff0d1da5719e4 /npc/test | |
parent | a9775a5447d35ef2b31e573a8e2e1dfe2d50bb9b (diff) | |
download | serverdata-e5534b4202c5b68d6b0fd0e2f01fae073aa7c8e7.tar.gz serverdata-e5534b4202c5b68d6b0fd0e2f01fae073aa7c8e7.tar.bz2 serverdata-e5534b4202c5b68d6b0fd0e2f01fae073aa7c8e7.tar.xz serverdata-e5534b4202c5b68d6b0fd0e2f01fae073aa7c8e7.zip |
Add functions and example npc for simple npc moving program.
For now npc AI support moving, changing direction, waiting.
Diffstat (limited to 'npc/test')
-rw-r--r-- | npc/test/_import.txt | 1 | ||||
-rw-r--r-- | npc/test/npc4.txt | 26 |
2 files changed, 27 insertions, 0 deletions
diff --git a/npc/test/_import.txt b/npc/test/_import.txt index 17a3a5cc..95322f03 100644 --- a/npc/test/_import.txt +++ b/npc/test/_import.txt @@ -4,3 +4,4 @@ npc: npc/test/_warps.txt npc: npc/test/npc1.txt npc: npc/test/npc2.txt npc: npc/test/npc3.txt +npc: npc/test/npc4.txt diff --git a/npc/test/npc4.txt b/npc/test/npc4.txt new file mode 100644 index 00000000..78103667 --- /dev/null +++ b/npc/test/npc4.txt @@ -0,0 +1,26 @@ +// Evol scripts. +// Authors: +// 4144 +// Description: +// test npc4 + +test,25,20,0 script npc4 801,{ + close; +OnTimer1000: + if (isunitwalking()) + { + initnpctimer; + end; + } + movetonextpos; + initnpctimer; + end; +OnInit: + initpath "move", 20, 20, + "dir", 6, 0, + "move", 25, 20, + "wait", 3, 0, + "move", 22, 10; + initialmove; + initnpctimer; +} |