Make Cabinet Open By It Self
Hey I was wondering if it was possible to open one of the two cabinet doors by it self?
I have tried:
With rotateArea:
///////////////////////////////////////////////////////////////////////////////////////////////
void CabinetScare(string &in asParent, string &in asChild, int alState)
{
AddTimer("", 2, "StopSound");
AddTimer("Cabinet", 0, "RotateArea")
PlaySoundAtEntity("creak", "joint_door_move_special.snt", "Cabinet", 1, false);
}
void RotateArea(string %in asTimer
{
if (GetLocalVarInt ("Check") == 0)
{
if (alState == 1)
{
SetMoveObjectState("Cabinet", 1);
SetLocalVarInt("Check", 1);
return;
}
}
)
void StopSound(string &in asTimer)
{
StopSound("creak", 0.4);
}
////////////////////////////////////////////////////////////////////////////////////////////
And I was thinking to try "prop Force" to but just wanted to hear if it was possible[/size][/font]
|