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
PrestoPimp
Apprentice


Joined: 18 Sep 2001
Posts: 175
Location: USA

PostPosted: Wed Oct 08, 2003 8:16 pm   

Walking around a map
 
How can i make something automated to where it will walk to every room on a map i create then go back to the beginning till a trigger tells it to start again?
Reply with quote
Vijilante
SubAdmin


Joined: 18 Nov 2001
Posts: 5182

PostPosted: Wed Oct 08, 2003 10:56 pm   
 
Create a path that hits every room, and loops back to the start room. This ensures you best routing to reduce duplication of steps.

Alternate methods might include using %mapfilter to limit searching to a specific zone, if you have other portions to your map. Then creating a list of all room numbers. Using %walk, %pathexpand, and %numitems, to determine closest room from list, then issuing #WALK with the closest room. Repeat closest test and walk until room list is empty, rooms would have to be removed from roomlist by way of the onroomenter alias, or room scripts.

Personally I think the path is the better way to go, unless you want the route to change dynamically based on time, random factors, or other things. Those were the reasons I had written my own slow walker once, and it was very effective at throwing off people trying to follow me that I didn't want to. It is definitely far too much work to recreate it though.
Reply with quote
PrestoPimp
Apprentice


Joined: 18 Sep 2001
Posts: 175
Location: USA

PostPosted: Wed Oct 08, 2003 11:05 pm   
 
Well I'm gonna be killing things along the way of walking slowly thru the very small map (15-20 rooms) and the way i got it now is an alarm for every 30 seconds to #step with the path.. but..sometimes it takes me longer than 30 seconds to kill something and the command will be sent to the mud throwing the whole walking path off course. Help plz :)
Reply with quote
DMUS
Beginner


Joined: 01 Sep 2003
Posts: 19
Location: USA

PostPosted: Thu Oct 09, 2003 3:32 am   
 
I made an autoratter for a subdivision in Achaea. Sounds similar to what you have. I knew each room was limited to 3 rats, but the time varied per room to kill 3 rats.

It had a timer and a variable for each step. I set up a trigger to add 1 to the variable whenever I killed a rat. When the variable hit 3 it would force the next step and also reset the variable to 0. If the timer reached 0, it would force a step and reset the variable to 0. Each step would reset the timer.

If you know how many mobs there will be, then you could do something similar.

Otherwise, you could do a look or something similar to see how many mobs are in the room, capture the number to a variable, subtract from it when you kill a mob, and step&reset when it reaches zero.

Kind of simplistic, but it worked for me.
Reply with quote
DMUS
Beginner


Joined: 01 Sep 2003
Posts: 19
Location: USA

PostPosted: Thu Oct 09, 2003 9:29 pm   
 
Of course, an autoratter is illegal in Achaea, so I don't use it. I wouldn't want to encourage anyone to violate any MUD rules. Wink
Reply with quote
Davos
Adept


Joined: 30 Jan 2003
Posts: 228
Location: USA

PostPosted: Thu Oct 09, 2003 9:41 pm   
 
Heh, Classic Recovery, *bravo*
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