Forwarded mail...

From: Billy H. Chan (~{3B:FH;~}) (bhchan@csua.berkeley.edu)
Date: 10/03/95


> From: Glenn Campbell <glenn@ccgc.tc.gc.ca>

> 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.

Sounds like you're looking for the 'rift' spell from MortalRealms (which
unfortunately is based on MERC).  The way they did it was to use a 'rift
number', some sort of reshuffled version of a room's vnum (shifted a few
places or had each digit replaced by another: 1 -> 5, 5-> 2, etc.) and
the necromancer (they have 4 specializations) would cast 'rift' <number>
<exit direction> and form a door between the current room in the chosen
direction to a random exit direction in the new place.  Thing about a 
rift was that it was a two way portal and remained virtually indefinitely.
The details are vague (they don't publish their code), but I think it had
something to do with adding a new door flag.  Also, somehow it knew to 
differentiate between players and only players in the same group as the
caster can use or even see the portal/rift.
Since the 'random' numbers are not as 'random' as looking for a mob or
a pc, it's easier to find the right place (just do a reverse replacement
(5 -> 1 and 2 -> 5 in my example above)).   
Whatcha think?
-Billy H. Chan	~{3B:FH;~}		    <bhchan@csua.berkeley.edu> 
 For more, check out http://www.csua.berkeley.edu/~bhchan



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