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
radboi22
Novice


Joined: 19 Jan 2008
Posts: 30

PostPosted: Sun Apr 12, 2009 9:51 pm   

MAPPER DIRECTIONS, SPEEDWALKING
 
Is there anyway to get mapper to send %1 %direction?
Example, during slow speedwalking, it sends east, waits for the ok, then sends the next directions,
how do I get it to add something before the sent direction, like, sprint east, sprint southwest, sprint north, instead of just the regular direction.

Thanks!
Reply with quote
Fang Xianfu
GURU


Joined: 26 Jan 2004
Posts: 5155
Location: United Kingdom

PostPosted: Sun Apr 12, 2009 10:02 pm   
 
Nope. Building a smarter pathfinder is something I hope will be easier after the next phases of the mapper rewrite, because muds have lots of different ways to get around.
_________________
Rorso's syntax colouriser.

- Happy bunny is happy! (1/25)
Reply with quote
ralgith
Sorcerer


Joined: 13 Jan 2006
Posts: 715

PostPosted: Mon Apr 13, 2009 2:23 am   
 
Erg, it should be noted that said mapper re-write is for CMUD ;)
_________________
CrossOver: Windows Compatibility on Mac and Linux CMUD Advocate
Reply with quote
MattLofton
GURU


Joined: 23 Dec 2000
Posts: 4834
Location: USA

PostPosted: Mon Apr 13, 2009 4:09 am   
 
Quote:

Is there anyway to get mapper to send %1 %direction?

Nope.


Actually, yes there is. #DIRECTION allows you to insert code into the speedwalk command. Macros don't use the #DIRECTION functionality, however, so if you want your macros to be included you might want to edit them from "n" to ".n".

Here's a very simple example:

#DIRECTION ns {%concat(@move,n)} n

When speedwalking, when @move is empty then it will just send "n" like normal. If you had to use the swim command, however, you could use the walk script in the mapper to set @move to "swim ", and at that point a speedwalk north from that room would automatically "swim north".

Like the OTHER COM field in the room properties window, the Direction textbox is simply not intended to hold significantly-sized code blocks. Keep it simple and small, and if you need something larger put it in a @function() or an alias (assuming using them in directions is allowed).

NOTE: some game commands move you multiple rooms at a time, so you'll want to include functionality somewhere to make sure your map location remains accurate (doing so might end up messing up mapper functionality like room scripts, since I don't know if #TELEPORT and other means to get there will activate those).
_________________
EDIT: I didn't like my old signature
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