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
GrimofDC
Beginner


Joined: 14 Jul 2002
Posts: 18

PostPosted: Sat Aug 03, 2002 9:30 pm   

mapping pitch black rooms
 
I'm having a hard time correctly mapping pitch black rooms. The mud I play has magically darkened rooms so sometimes I will not be able to see the room title, desc, exits etc... So far I've done this

#MAKEROOM %lastcom2 {It is pitch black...}

This correctly makes a room if I'm mapping solo, it does not work if I'm following someone unfortunately because it is grabbing the direction from the %lastcom2 variable, but my main problem is it will mess up whenever I walk back through the room. This causes a lot of overlapping. I would like to be able to enter pitch black rooms or follow someone into pitch black rooms and create a new room if it is needed, otherwise if a pitch black room is already in that direction don't make a new one.

Here is some mud output:

Wall Road
Wall Road ends abruptly here and you find yourself in one of the
less reputable parts of Sorpigal. To the north lies the entrance
to the shopping district and the city gates. To the east there is
a small alley that leads to an apparently abandoned part of town.
Exits: north east

90/90hp 224/224m 133/141mv -712al >
e
It is pitch black...

90/90hp 224/224m 139/141mv -712al >
e
Beginning of White Dragon Boulevard
This section of town has been overrun by the Troll gang. Even the
police stay out of here for fear of being brutalized. This was once
a nice lower-middleclass neighborhood, but now the gangs run the
streets. All the shops and homes have been boarded up and abandoned.
An alleyway is to the west and the street continues east. An over-
grown lot is to the south.
A patrolman is trying to keep the peace.
Exits: west south east

I would appreciate any help, and thank you in advance!
Reply with quote
Vijilante
SubAdmin


Joined: 18 Nov 2001
Posts: 5182

PostPosted: Sat Aug 03, 2002 11:19 pm   
 
#VAR IsFollowing 0
#VAR LastDir ""
#TR {^You follow %w (%w).$} {IsFollowing=1;LastDir="%1"}
#TR {^You no longer follow %w.$} {IsFollowing=0}
#TR {^It is pitch black...$} {#IF (@IsFollowing=0} {#IF (%lastdir) {LastDir=%lastdir} {LastDir=""}};#IF (@LastDir) {#IF (%roomlink(%roomnum,@LastDir)>0) {#OK} {#IF (%trigger(AutoMapper)) {#MAKEROOM @LastDir}}}}

That should do it. You will have to customize the following triggers to match your muds exact output.

For an explanation it checks to see where it can get your last direction from, either the automapper queue, or from what the follow trigger stored. Then if it has a direction it checks to see if there is already a room that way. Many muds have a light level on rooms so a room might be pitch black because your light went out if there is a room it sends #OK otherwise it creates a room if you are currently in map mode.
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