|
Spondodge Newbie
Joined: 09 Feb 2004 Posts: 5 Location: United Kingdom
|
Posted: Mon Feb 09, 2004 9:19 pm
Some Help with Auto move/kill PLZ |
An auto move and kill script I have been working on, at the moment I have designed it to move one direction on a premade path and if it see's a animal it is suppost to kill it will kill it then "look" again to see if there's anything else it can kill. If nothings in the room, it moves on to next direction. I could really do with some help on it though. :(
For example, this one kills dogs... If there is more than one dog in a room, it will kill the first one, then look, then kill second.. etc.
Basically I start it by doing, #slow pathname
however... It seems to move two directions of my slow path, then just time out and say "Slow Walk Aborted." I am using Zmud 6.67
By the way, if there's anyone who wants to rewrite it :) Feel free... I originally wanted to rewrite it to allow for adding Animals
to a database for what you will attack and what you won't.
#class {carnage}
#trigger {^A small dog is sitting here.$} {#t- waiting;#t- carnage;kill dog;tgt = dog;#t+ follower}
#class 0
#class {follower}
#TRIGGER {^A small dog leaves east.$} {east;#if (@goback) {#add goback ";w"} {#var goback "w"}}
#TRIGGER {^A small dog leaves south.$} {south;#if (@goback) {#add goback ";n"} {#var goback "n"}}
#TRIGGER {^A small dog leaves west.$} {west;#if (@goback) {#add goback ";e"} {#var goback "e"}}
#TRIGGER {^A small dog leaves north.$} {north;#if (@goback) {#add goback ";s"} {#var goback "s"}}
#TRIGGER {^A small dog is dead! R.I.P.$} {sc;@goback;goback ="";#t+ carnage;look;#t+ waiting}
#class 0
#class {waiting}
#TRIGGER {[ obvious exits:} {#ALARM +5 {#STEP;#ok}}
#class 0
Thanks.. |
|
|
|
Spondodge Newbie
Joined: 09 Feb 2004 Posts: 5 Location: United Kingdom
|
Posted: Tue Feb 10, 2004 1:03 am |
changed it a little, it still doesn't work properly though :P The movement is screwed...
#class {carnage}
#trigger {^A small dog is sitting here.$} {#pause;#t- waiting;#t- carnage;kill dog;#t+ follower}
#class 0
#class {follower}
#TRIGGER {^A small dog leaves east.$} {#t+ carnage;east;#if (@goback) {#add goback ";w"} {#var goback "w"}}
#TRIGGER {^A small dog leaves south.$} {#t+ carnage;south;#if (@goback) {#add goback ";n"} {#var goback "n"}}
#TRIGGER {^A small dog leaves west.$} {#t+ carnage;west;#if (@goback) {#add goback ";e"} {#var goback "e"}}
#TRIGGER {^A small dog leaves north.$} {#t+ carnage;north;#if (@goback) {#add goback ";s"} {#var goback "s"}}
#TRIGGER {^A small dog is dead! R.I.P.$} {sc;@goback;goback ="";#t+ carnage;look;#t+ waiting}
#class 0
#class {waiting}
#TRIGGER {[ obvious exits:} {#ALARM +5 {#STEP}}
#class 0 |
|
|
|
Spondodge Newbie
Joined: 09 Feb 2004 Posts: 5 Location: United Kingdom
|
Posted: Tue Feb 10, 2004 11:45 am |
ok since no one seems to be able to help me with the script, (thats ok.. no probs) Perhaps someone can explain to me about how #slow is used.
For instance, do I need to set anything in mapper configurations or preferences in zmud to make it work better?
Why doesn't my mapper follow the #slow path?
umm, does it do the path auto? Or does it need to see #step for each room or #ok or something??
Does doing a command like "look" interupt a #slow path?
Is it something to do with me using zmud 6.67 beta?
Thanks.. |
|
|
|
Rorso Wizard
Joined: 14 Oct 2000 Posts: 1368
|
Posted: Tue Feb 10, 2004 1:13 pm |
quote: Originally posted by Spondodge
ok since no one seems to be able to help me with the script, (thats ok.. no probs) Perhaps someone can explain to me about how #slow is used.
For instance, do I need to set anything in mapper configurations or preferences in zmud to make it work better?
Why doesn't my mapper follow the #slow path?
umm, does it do the path auto? Or does it need to see #step for each room or #ok or something??
Does doing a command like "look" interupt a #slow path?
Is it something to do with me using zmud 6.67 beta?
Thanks..
There's a description of slow walking here: http://www.zuggsoft.com/library/book3/speedwalking.htm
However note that using slow is not the only method... Another way is to use a variable and an index. |
|
|
|
Spondodge Newbie
Joined: 09 Feb 2004 Posts: 5 Location: United Kingdom
|
Posted: Tue Feb 10, 2004 8:20 pm |
I took your advice and used the variable and index method, it works really well now apart from #t+ and #t- triggers conflicting here and there when things happen at particular times in conjunction on the mud. So I have a lot of bugs to work out still.
But thanks for the idea, it's helped a lot :) |
|
|
|
|
|