53 lines
1.0 KiB
Plaintext
53 lines
1.0 KiB
Plaintext
/* Script generated by
|
|
Lilac Soul's NWN Script Generator, v. 1.6
|
|
|
|
For download info, please visit:
|
|
http://www.lilacsoul.revility.com */
|
|
|
|
//Put this OnEnter
|
|
void main()
|
|
{
|
|
|
|
object oPC = GetEnteringObject();
|
|
|
|
if (!GetIsPC(oPC)) return;
|
|
|
|
if (GetItemPossessedBy(oPC, "doorikon")!= OBJECT_INVALID)
|
|
return;
|
|
|
|
CreateItemOnObject("doorikon", oPC);
|
|
|
|
object oTarget;
|
|
oTarget = GetObjectByTag("hulkdoor1");
|
|
|
|
AssignCommand(oTarget, ActionCloseDoor(oTarget));
|
|
|
|
SetLocked(oTarget, TRUE);
|
|
|
|
oTarget = GetObjectByTag("hulkdoor2");
|
|
|
|
AssignCommand(oTarget, ActionCloseDoor(oTarget));
|
|
|
|
SetLocked(oTarget, TRUE);
|
|
|
|
oTarget = GetObjectByTag("hulkdoor1");
|
|
|
|
DelayCommand(90.0, SetLocked(oTarget, FALSE));
|
|
|
|
DelayCommand(90.0, AssignCommand(oTarget, ActionOpenDoor(oTarget)));
|
|
|
|
oTarget = GetObjectByTag("hulkdoor2");
|
|
|
|
DelayCommand(90.0, SetLocked(oTarget, FALSE));
|
|
|
|
DelayCommand(90.0, AssignCommand(oTarget, ActionOpenDoor(oTarget)));
|
|
|
|
object oItem;
|
|
oItem = GetItemPossessedBy(oPC, "doorikon");
|
|
|
|
if (GetIsObjectValid(oItem))
|
|
DelayCommand(90.0, DestroyObject(oItem));
|
|
|
|
}
|
|
|