Itskody
Member
Posts: 100
Threads: 30
Joined: Mar 2011
Reputation:
1
|
how to open iron maiden?
I was wondering what script to use to have the iron maiden ( the coffin thing with nails) to open up automatically after i walk over a collide script..
So when i walk over a collide script the coffin swings open.
|
|
04-18-2011, 09:59 PM |
|
Anxt
Senior Member
Posts: 588
Threads: 12
Joined: Mar 2011
Reputation:
10
|
RE: how to open iron maiden?
AddPropImpulse(blahblahblah)
is the function you are looking for. The iron maiden acts as a swing door, so anything you can do with a door will work on the IM as well.
|
|
04-18-2011, 10:11 PM |
|
Itskody
Member
Posts: 100
Threads: 30
Joined: Mar 2011
Reputation:
1
|
RE: how to open iron maiden?
but wont that move the whole thing? instead of just open the doors?
|
|
04-18-2011, 10:13 PM |
|
Anxt
Senior Member
Posts: 588
Threads: 12
Joined: Mar 2011
Reputation:
10
|
RE: how to open iron maiden?
No, because the rest of the iron maiden is considered to be static by the game. Its like if you checked the "static physics" box in the editor for something. So don't worry, it will only move the doors.
|
|
04-18-2011, 10:23 PM |
|
Itskody
Member
Posts: 100
Threads: 30
Joined: Mar 2011
Reputation:
1
|
RE: how to open iron maiden?
hmm it doesnt open much, only opens a crack.. tell me if this is right please:
AddPropImpulse("iron_maiden_1", 40, 1, -27.25, "world");
|
|
04-18-2011, 10:43 PM |
|
Anxt
Senior Member
Posts: 588
Threads: 12
Joined: Mar 2011
Reputation:
10
|
RE: how to open iron maiden?
Just give it a one-directional push instead of a multi-directional. Give the push in the direction the IM is facing, and if you want it to open quickly, make the number roughly 5000 or so, just to make sure it works. For slower things, you may need to use a timer to repeatedly call a function that gives it a little push every so often.
|
|
04-18-2011, 10:58 PM |
|
Itskody
Member
Posts: 100
Threads: 30
Joined: Mar 2011
Reputation:
1
|
RE: how to open iron maiden?
ok i got it thanksss
(This post was last modified: 04-18-2011, 11:08 PM by Itskody.)
|
|
04-18-2011, 11:03 PM |
|
Anxt
Senior Member
Posts: 588
Threads: 12
Joined: Mar 2011
Reputation:
10
|
RE: how to open iron maiden?
no problem
|
|
04-18-2011, 11:20 PM |
|