58 lines
1.3 KiB
Plaintext
58 lines
1.3 KiB
Plaintext
|
//::///////////////////////////////////////////////
|
||
|
//:: Trap door that takes you to a waypoint that
|
||
|
//:: is stored into the Destination local string.
|
||
|
//:: FileName
|
||
|
//:: Copyright (c) 2001 Bioware Corp.
|
||
|
//:://////////////////////////////////////////////
|
||
|
/*
|
||
|
|
||
|
*/
|
||
|
//:://////////////////////////////////////////////
|
||
|
//:: Created By: Robert Babiak
|
||
|
//:: Created On: June 25, 2002
|
||
|
//:://////////////////////////////////////////////
|
||
|
|
||
|
void main()
|
||
|
{
|
||
|
object oidUser;
|
||
|
object oidDest;
|
||
|
string sDest;
|
||
|
int nIdx;
|
||
|
object oAssociate;
|
||
|
|
||
|
if (!GetLocked(OBJECT_SELF) )
|
||
|
{
|
||
|
if ( GetIsOpen(OBJECT_SELF))
|
||
|
{
|
||
|
sDest = "DST_"+GetTag( OBJECT_SELF );
|
||
|
|
||
|
oidUser = GetLastUsedBy();
|
||
|
oidDest = GetObjectByTag(sDest);
|
||
|
|
||
|
for (nIdx=1;nIdx<=5;nIdx++)
|
||
|
|
||
|
{
|
||
|
oAssociate=GetAssociate(nIdx,oidUser);
|
||
|
if (GetIsObjectValid(oAssociate))
|
||
|
{
|
||
|
AssignCommand(oAssociate, JumpToObject(oidDest,FALSE));
|
||
|
}
|
||
|
}
|
||
|
|
||
|
AssignCommand(oidUser, ActionJumpToObject(oidDest,FALSE));
|
||
|
//PlayAnimation(ANIMATION_PLACEABLE_CLOSE );
|
||
|
|
||
|
|
||
|
|
||
|
} else
|
||
|
{
|
||
|
PlaySound("as_dr_woodlgop1");
|
||
|
PlayAnimation(ANIMATION_PLACEABLE_OPEN );
|
||
|
}
|
||
|
} else
|
||
|
{
|
||
|
// ActionUseSkill
|
||
|
}
|
||
|
|
||
|
}
|