Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Opening Closet/Cabinets?
JoeBradleyUK Offline
Member

Posts: 115
Threads: 20
Joined: Jul 2011
Reputation: 0
#1
Opening Closet/Cabinets?

I want to open a cabinet when i walk near it, i know how to script it but i don't know the function, i tried:

SetSwingDoorClosed(string& asName, bool abClosed, bool abEffects);

but that didn't work any ideas?

:Work In Progress:
Insanity
(This post was last modified: 07-26-2011, 04:48 PM by JoeBradleyUK.)
07-26-2011, 12:29 PM
Find
Kyle Offline
Posting Freak

Posts: 911
Threads: 36
Joined: Sep 2010
Reputation: 7
#2
RE: Opening Closet/Cabinets?

I don't think that works at all. Try using a "AddPropImpulse(string& asName, float afX, float afY, float afZ, string& asCoordSystem);" function.

07-26-2011, 12:31 PM
Find
JoeBradleyUK Offline
Member

Posts: 115
Threads: 20
Joined: Jul 2011
Reputation: 0
#3
RE: Opening Closet/Cabinets?

(07-26-2011, 12:31 PM)Kyle Wrote: I don't think that works at all. Try using a "AddPropImpulse(string& asName, float afX, float afY, float afZ, string& asCoordSystem);" function.

won't that push the cabinet altogether and not the doors Tongue?

Well, i'll test it out anyway

:Work In Progress:
Insanity
(This post was last modified: 07-26-2011, 12:37 PM by JoeBradleyUK.)
07-26-2011, 12:35 PM
Find
Kyle Offline
Posting Freak

Posts: 911
Threads: 36
Joined: Sep 2010
Reputation: 7
#4
RE: Opening Closet/Cabinets?

(07-26-2011, 12:35 PM)JoeBradleyUK Wrote:
(07-26-2011, 12:31 PM)Kyle Wrote: I don't think that works at all. Try using a "AddPropImpulse(string& asName, float afX, float afY, float afZ, string& asCoordSystem);" function.

won't that push the cabinet altogether and not the doors Tongue?

The cabinet is in a fixed condition, not the doors. If you have the function set up in the correct x, y, z vector, then it should blast the doors open. It's best to start at a small number like 1 so the doors don't glitch and get stuck and make it look messed up. Tongue

(This post was last modified: 07-26-2011, 12:38 PM by Kyle.)
07-26-2011, 12:38 PM
Find
JoeBradleyUK Offline
Member

Posts: 115
Threads: 20
Joined: Jul 2011
Reputation: 0
#5
RE: Opening Closet/Cabinets?

(07-26-2011, 12:38 PM)Kyle Wrote:
(07-26-2011, 12:35 PM)JoeBradleyUK Wrote:
(07-26-2011, 12:31 PM)Kyle Wrote: I don't think that works at all. Try using a "AddPropImpulse(string& asName, float afX, float afY, float afZ, string& asCoordSystem);" function.

won't that push the cabinet altogether and not the doors Tongue?

The cabinet is in a fixed condition, not the doors. If you have the function set up in the correct x, y, z vector, then it should blast the doors open. It's best to start at a small number like 1 so the doors don't glitch and get stuck and make it look messed up. Tongue

It's worked thanks!

:Work In Progress:
Insanity
07-26-2011, 04:34 PM
Find




Users browsing this thread: 1 Guest(s)