//////////////////////////////////// //Created By: Genisys / Guile //Created On: 7/01/08 /////////////////////////////////////////// /* ***IMPORTANT**** This script goes in the OnUsed Event of a Placeable Control or Switch, it should be used on something ALL PCs must use to enter the module preferrably. YOU MUST SET THE TAGNAME BELOW! */ //////////////////////////////////////////// //Change "home" below to the tagname of //the waypoint you want the PCs to teleport //to after they use the scan switch. const string sWay = "home"; //Always use the " " ///////////////////////////////////////////// //Main Script (DON'T TOUCH ANYTHING BELOW!) ///////////////////////////////////////////// void main() { //Define Major Variables object oPC = GetLastUsedBy(); //If it's not a PC Stop here! if(!GetIsPC(oPC))return; //Do this only one time per PC per restart.. if(GetLocalInt(oPC, "iSwitchScan")==2) { //Stop the script dead here! return; } //Othewise they must have never done this.. continue on! else { //NOTE: You can make it always scan every PC ever time //Simply type // at the start of the line below to make this always active.. SetLocalInt(oPC, "iSwitchScan", 2); } //First make the PC Unequip all items they are wearing //If the items were not unequipped some might be missed (bug) object oSlot; int nSlot; for (nSlot=0; nSlot