11-27-2011, 03:52 PM
I relay want to know how to creek open a door slowly like in the first level of amnesia.
This is my script so far but it does not have any effects on the door.
////////////////////////
void OnStart()
{
AddEntityCollideCallback("Player", "opendoor", "opendoorfunc", true, 1);
}
void opendoorfunc(string &in asParent, string &in asChild, int alState)
{
SetSwingDoorClosed("cellar_wood01_slow_1", false, false);
AddPropForce("cellar_wood01_slow_1", 90, 0, 0, "world");
}
If anyone like to help me out on this or know how to creek open a door, just like on the first level of amnesia please let me know. Thanks!
This is my script so far but it does not have any effects on the door.
////////////////////////
void OnStart()
{
AddEntityCollideCallback("Player", "opendoor", "opendoorfunc", true, 1);
}
void opendoorfunc(string &in asParent, string &in asChild, int alState)
{
SetSwingDoorClosed("cellar_wood01_slow_1", false, false);
AddPropForce("cellar_wood01_slow_1", 90, 0, 0, "world");
}
If anyone like to help me out on this or know how to creek open a door, just like on the first level of amnesia please let me know. Thanks!