35 lines
927 B
Plaintext
35 lines
927 B
Plaintext
|
//trapdoor_yes script by Kerico 7/7/02
|
||
|
//jumps the using PC to target waypoint and closes the trapdoor for next use
|
||
|
//place in action taken scipt in trapdoor conversation
|
||
|
//in 'yes' end dialog of the trapdoor
|
||
|
#include "nw_i0_tool"
|
||
|
void main()
|
||
|
{
|
||
|
object oPC = GetPCSpeaker();
|
||
|
string check = GetLocalString(oPC, "doublecheck");
|
||
|
string name1 = GetPCPlayerName(oPC);
|
||
|
if (check != name1){
|
||
|
return;
|
||
|
}
|
||
|
if(!HasItem(oPC, "rainbowstone")){
|
||
|
string name = GetPCPlayerName(oPC);
|
||
|
SetXP(oPC, 0);
|
||
|
BootPC(oPC);
|
||
|
SendMessageToAllDMs( name + " has been invalidated for attempting to exploit teleporter.");
|
||
|
|
||
|
}
|
||
|
|
||
|
//get the target waypoint destination
|
||
|
object oDrop = GetWaypointByTag("rainbow2");
|
||
|
|
||
|
//jump the PC to the destination
|
||
|
AssignCommand (oPC,JumpToObject(oDrop));
|
||
|
object oItemToTake;
|
||
|
oItemToTake = GetItemPossessedBy(GetPCSpeaker(), "rainbowstone");
|
||
|
if(GetIsObjectValid(oItemToTake) != 0)
|
||
|
DestroyObject(oItemToTake);
|
||
|
|
||
|
|
||
|
|
||
|
}
|