Find
You are looking at a command called exit
exit
Travel out the first object found called an 'exit' if there is one.
exit
read the command called build
to find out how to build new locations.
Created by
wolis
, last updated 12 Jul 2012
Code
foreach in $loc do checkit;
if $target's link > 0 then islinked else noexit;
##checkit:
if $for_id's class like exit then useit else fail;
##useit:
var $target to $for_id;
##islinked:set $actor's pose to '';
var $tlink to $target's link;
if $target's link > 0 then newloc else noexit;
##newloc:
say 'leaves',"[$actor] leaves via [$target]";
set $actor's loc to $tlink's loc;
msg $loc,$actor,0,0,'force',"force:look $loc";
var $loc to $actor's loc;
say 'arrives',"[$actor] appears via [$tlink]";
set $actor's host to $tlink;
set $actor's hosthow to 'beside';
look $loc;
msg $loc,$actor,0,0,'force',"force:look $loc";
##noexit:
say 'look',"[$actor] looks around for an exit but could not find one";
look $loc;
msg $loc,$actor,$actor,0,'force',"force:look $loc";