Re: Named Exits (go shop ect....)

From: Brandon Brown (
Date: 10/03/00

.> Hello, I am a newbie coder that is just starting to get the basic
> elements of coding. I posted this in the previous month, September, and
> didnt get that much of a responce.
Oh contrare, mon amise!  I responed with a mini tutorial!  Here it is again
;) If it's code you're looking for though - we're not going to do this work
for you ;)

    I coded this a while ago - 'borrowed' the idea from a game called Modus
Operandi.  It's actually enormously simple and I did it when I had an even
weaker grip on the code than I do now.

    Look at your current movement and directions code - herein is where I
added mine.  I'm not going to give you the actually code for two reasons a)
you'll never learn anything b) my code is so incomprehensible with commented
out parts here and there it's simply not worth translating. ;)  But here's
how I went about doing it:

    Add two or three new exits (go, go-a, go-b), etc, depending on how many
go exits you'd like to exist in a room.

    Create a go command to look for these exits and move players around if
they exist.

    Really simple :)  This probably isn't the best way to do it - I'm sure
there's easier and less draining ways - but it's how I pulled it together
and it works quite nicely for me :)  I used the gen-desc to hold a string
that'd show:

sprintf(buf2, "$n %s %s", GET_LASTNAME(ch), (EXIT(ch,

    Which helps to differentiate between different exits - rather than
taking the whole '$n has left the room' approach which is so horribly boring

    Anyways, hope that helps :)

  B. Brown                                                     TimeTraveller
  Senior Programmer                                      'Lost in Time,
  U&A Software InterActive                            'and Loving it!'

     | Ensure that you have read the CircleMUD Mailing List FAQ:  |
     |  |

This archive was generated by hypermail 2b30 : 04/10/01 PDT