/******************************************************************************* Plugin Teleport Client part Version: 1.0 Authors: Sylvain HUET & Sebastien DENEUX Last update: 20/05/2001 *******************************************************************************/ /******************************************************************************* clic sur le lien -> demande de teleportation *******************************************************************************/ fun cbLinkClick(o, h, m, b, param) = if b != 1 then nil else _DMSevent this strcat class ".teleport" param nil ;; /******************************************************************************* New object creation o -> Ob : object <- I : not used *******************************************************************************/ fun newOb(o) = let hd UgetParam ObUi o "room_name" -> room_name in let hd UgetParam ObUi o "position" -> position in let hd UgetParam ObUi o "alias" -> alias in match hd ObAnchor o with (objAnchor [ah am _ _] -> ( ObSetLinks o [ah am alias HandCursor mkfun5 @cbLinkClick strbuild ("room_name"::room_name::nil)::("position"::position::nil)::nil nil nil]::nil; 0 ) ) ;; /******************************************************************************* Function called when plugin is initialised file -> S : '*.plug' file name <- I : not used *******************************************************************************/ fun IniPlug(file) = set class = getInfo strextr _getpack _checkpack file "name"; PLUGsetinfo thisplug PLUGIN_ONLINE_EDITING|PLUGIN_NOTRESERVED|PLUGIN_MATERIAL; PLUGdefineEditor thisplug @dynamicedit; PlugRegister class @newOb nil; 0 ;;