Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » zMUD General Discussion
einar
Wanderer


Joined: 06 Nov 2000
Posts: 80
Location: USA

PostPosted: Thu Dec 27, 2001 2:10 am   

Simply Bot
 
Hi, is there any way to make my extremely simply bot work?
I have my area mapped out, so i want to start at room #0, and kill a duck in each room.
Each room could have any amount of ducks.
So how would I make it so that i enter a new room, kill a duck, after the last duck is dead, go to the next room (I was thinking via #ADD gotoroom 1;#WALK @gotoroom), and repeat until i get to the last room (in this case #24)
I also want it to be really adaptable, so that i can use this same bot over any area I might want to use it on, and have already mapped.
I've tried doing it all myself, by automatically killing a new duck after one dies, and if there are no ducks left, add 1 to gotoroom, and #WALK there, but it seems to always go wrong (Slow walking aborts, then mapper doesn't follow me in follow mode, and the whole thing goes wrong)
Anyone know how to make a new one that works?
Heres some info you'll probably need, please ask if you need anything else:

HP: 500/500 SP: 200/200 E: 400/400 >
Big duck falls and DIES!
There is no a duck here.

Thats would be my prompt on the first line, the death message on the second line, and the message I get when there are no ducks left on the third line.




<IMG SRC="http://www.ahira.f2s.com/signature.jpg">
Reply with quote
einar
Wanderer


Joined: 06 Nov 2000
Posts: 80
Location: USA

PostPosted: Thu Dec 27, 2001 2:15 am   
 
Umm.. topic should be Simple Bot
I typo too much :P

Also, is there any way to pause the bot when my hit points falls below 300? Then have it start back up again when I'm fully healed.
The message when I'm fully healed is:
You feel fully healed.

Reply with quote
iljhar
GURU


Joined: 10 Oct 2000
Posts: 1116
Location: USA

PostPosted: Thu Dec 27, 2001 7:24 am   
 
There was something similar to this, something about collecting mushrooms or something like that. Anyways, you can do something like this:

#alias duckon {#t+ DuckKillingSpree;#var gotoroom 0;kill duck}

#alias duckoff {#t- DuckKillingSpree;#say Your duck killing spree is over!}

#alias keepgoing {#add gotoroom 1;#walk @gotoroom} "DuckKillingSpree"

#trigger {Big duck falls and DIES!} {#if (@GoodHPs=1) {kill duck}} "DuckKillingSpree"

#trigger {There is no a duck here.} {#if (@GoodHPs=1) {#if (@gotoroom>=24) {duckoff} {keepgoing}}} "DuckKillingSpree"

#trigger {You feel fully healed.} {#if (@GoodHPs=0) {#var GoodHPs 1;#if (@gotoroom>=24) {duckoff} {keepgoing}}} "DuckKillingSpree"

#trigger {^HP~: (%d)/%d SP~: %d/%d E~: %d/%d >} {#if (%1<300) {#var GoodHPs 0} "DuckKillingSpree"

All untested code, your miles may vary.

Iljhar
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » zMUD General Discussion All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net