Posted By
|
Message
|
aaron_brammer
Registered 14/05/2003
Points 1299
|
7th July, 2003 at 01:13:40 -
ok, im making die hard game and i need to know how to push an object with my character in a platform game (for the c4 scene and the dropping of the body).
heyo
|
Shen Possibly Insane
Registered 14/05/2002
Points 3497
|
7th July, 2003 at 01:22:47 -
Assign them platform movement with Player 4, then adjust the positions for pushing - If player is to the left of it and walks towards it, add 2 to its X value, and vice verca et al.
gone fishin'
|
aaron_brammer
Registered 14/05/2003
Points 1299
|
7th July, 2003 at 04:48:10 -
thats ok for the c4, but how dould i do it efficiently for enemies that dont have player movement, i want it so its possible to push any dead enemy out the window
heyo
|
Shen Possibly Insane
Registered 14/05/2002
Points 3497
|
7th July, 2003 at 08:36:16 -
Give all the enemies player movement?
The other way involves something complicated with fastloops and detectors and a custom gravity engine. It's not worth it.
gone fishin'
|
Rycon
Registered 20/09/2002
Points 996
|
7th July, 2003 at 11:29:07 -
No no, it IS worth it, and its easy.
First make a detector shaped like this >
Always: place the detector on the right side of your guy.
If the detector is overlaping the body, set X posistion of body + 2 (Or whatever matches the speed of your guy.)
Now you will need a detector shaped like this _
Always: Place the detector at the bottem of your body.
If the detector is NOT (Negate) overlapping a backdrop, every like 10 miliseconds set Y position of body + 3
If you want them to fall smoothly or gain momentum as they fall, look at the post Chunks Flying Off enemies, there is a very simple gravity tutorial I wrote there. Even make em bounce when they hit the ground!
We are the music makers, we are the dreamers of dreams...
|
|
|