Frictional Games Forum (read-only)

Full Version: Door Force Won't Open Door!
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Okay... So everyone makes maps with a door that swings open on it's own.
and I need that in my map... But for some reason that I can CEASE to
understand is that the door DOES NOT OPEN on its own. It pushes out for a
moment but shoots RIGHT BACK to the closed position, no matter how high
I put the coordinate values. I used the wiki, other scripts, and it's
failing to do as it is told. Coulc someone for the life of me, tell me
what the fack I am doing wrong? My script:

//____________________________________
void OnStart()
{
AddEntityCollideCallback("Player", "OpenDoor", "pushdoor", true, 1);
}
void pushdoor(string &in asParent, string &in asChild, int alState)
{
SetSwingDoorClosed("Dog_door", false, true);
SetSwingDoorDisableAutoClose("Dog_door", true);
AddPropForce("Dog_door", 0, 0, 15000, "world");
}
//____________________________________
Try disabling the autoclose before you try to open the door with SetSwingDoorClosed.
(11-02-2011, 12:33 AM)Your Computer Wrote: [ -> ]Try disabling the autoclose before you try to open the door with SetSwingDoorClosed.
Did that AND deleted the doorframe. It's still not working. It's like the door is getting caught on itself... This script has NEVER wanted to work for me.
(11-02-2011, 12:55 AM)Statyk Wrote: [ -> ]Did that AND deleted the doorframe. It's still not working. It's like the door is getting caught on itself... This script has NEVER wanted to work for me.

Then i can only suggest to pull the door out of its frame (perhaps even in the air) and test it out. If it still doesn't work, then try a negative value for the prop force. If it works then, then the issue was improper placement of the door. If it still doesn't work, then i don't know (aside from cache conflicts).
(11-02-2011, 01:16 AM)Your Computer Wrote: [ -> ]
(11-02-2011, 12:55 AM)Statyk Wrote: [ -> ]Did that AND deleted the doorframe. It's still not working. It's like the door is getting caught on itself... This script has NEVER wanted to work for me.

Then i can only suggest to pull the door out of its frame (perhaps even in the air) and test it out. If it still doesn't work, then try a negative value for the prop force. If it works then, then the issue was improper placement of the door. If it still doesn't work, then i don't know (aside from cache conflicts).
Maybe your pushing the door so hard it comes back to the frame? Try lowering to like 10 or something./
(11-02-2011, 02:42 AM)flamez3 Wrote: [ -> ]Maybe your pushing the door so hard it comes back to the frame? Try lowering to like 10 or something./
I'll give that a shot, thanks...


I suppose i should mention that you don't need more than 1000 force for an instantly opening door; 500 for a slowly opening door.
(11-02-2011, 02:55 AM)Your Computer Wrote: [ -> ]I suppose i should mention that you don't need more than 1000 force for an instantly opening door; 500 for a slowly opening door.
That could be a big issue.... >> would setting it too high make it freak out like it is doing? lol It nearly broke off it's hinges.
What do you have the force set at right now?

-Grey Fox
Try using AddPropImpulse. It functions the same way but the values necessary to move the prop are way lower.