From: Andrew Paprocki (
Date: 10/03/95

>At 10:18 AM 10/3/95 -0300, Glenn Campbell wrote:
>Im looking to code a spell in Circle 3.00 that will allow a caster to create
>a temporary portal to another
>room in the mud. The syntax would be something like cast 'spellname' <mob>
>or cast 'spellname' <pcname>. I am planning on setting it up so the pcs will
>simply type somethink like "enter portal" and they will come out in the
>other room. IF anyone has coded something similar to this I would be really
>interested in how you did it. I am beating my head against the wall thinking
>of ways to do it.

I have implemented this on our mud... what you do is add in a room flag
called ROOM_GATE and then have the spell go like this...

cast 'gate' person
        check for any restricts you want
        get the room# of person
        ch->in_room.to_room=room# of person
        ch->in_room gets ROOM_GATE set
        "You open a portal" -> ch
        "Blah opens a portal" -> ch->in_room

then, in the look_room code, change it so that if a room is flagged
ROOM_GATE, it says there's a gate there.

Temple of Midgaard
blah blah blah
There is a pulsating portal here!
Dork is standing here.

finally, edit the do_enter code so that if the person types enter gate or
enter portal in a room that is flagged ROOM_GATE, it teleports them to the
room saved when the spell was cast and displays a message like "Blah arrives
through a portal in the sky!" I also added code to make the portals
automatically close (in comm.c) every 40 seconds or so.. not the best way
for a timer but it works.. The room_data structure must also be altered to
add a variable called to_room..

Hope that helps.. it works for me so it should give you ideas if you want to
use/modify this system.. 

BTW, the restricts I like are that no mortals can teleport to god rooms or
houses and only PC's can be specified.. there can't be gates to mobs because
then travel would be obsolete.. Any other ideas/suggesstions could be sent
my way.. I would like to make it check a percent chance on your level and if
you fail, your teleport goes awry and you get pulled out of your travel by
demons and you must kill them to get back to the mortal plane.. but then
again, that's just another evil idea.. muhaha :)

This archive was generated by hypermail 2b30 : 12/07/00 PST