Need help on physics for platformer.

Get help using Construct 2

Post » Sat Jun 02, 2012 8:49 pm

Hi guys, I could really use some advice on character movement for a platform game I'm making, were a new Dev team and have so far been really successful, but we seem to have hit a bit of a wall.

The idea is to implement physics behaviour to certain interactive objects.
Think of rolling boulders and dragging boxes, similar to Limbo.
Now since Physics and Platform behaviour don't mix very well, I'm having some trouble finding a good way to create smooth character movement.

So far I've tried to do the movement and interaction in 3 different ways. As can be seen in the following .capx files.

Method 1 (click for .capx file):
Platform behaviour on the character with manually added force/impulses/torque on objects by using the on collision/on overlapping conditions.
Method 2 (click for .capx file):
Physics controlled movement. Character moves by force and jumps by impulse.
Method 3 (click for .capx file):
The character has platform behaviour and gets replaced by a physics controlled character on collision/overlap with an interactive object.

However, each of these 3 methods have some issues, mainly the following:

Method 1:
The character sticks to almost vertical walls.
The interaction with objects is limited and somewhat unrealistic, giving the character a stuttering movement.

Method 2:
The character gets airborne when he moves over a ramp. I would like it to stick to the floor unless the jump button is used. I would like the movement to be very similar to platform behaviour.

Method 3: Like in the first method, the character pushes an object with stuttering movement. Also the character starts moving in a strange way whenever he is on top of an interactive object, this is probably because of how I made the event sheet, but I can't seem to fix it.

I would really like some advice here, it's my first time using construct.
Which method do you guys think is the best for a platform game with physics? And how would I set it up to avoid the problems I have in these examples?
Posts: 11
Reputation: 372

Post » Sun Jun 17, 2012 12:34 pm

Hi mate,

I'm pretty new to this stuff, but was looking for something similar. The easiest way I found was creating a sprite set to invisible on start the same size as my character, I placed the box over the character and applied physics to it, and platform behaviour to character. I then said- every tick-pin to- character. This way I can use the character for movement and the box works with physics interactions.

Now I just have to figure out how to manipulate the platform behaviour.

Hope this helps
Posts: 26
Reputation: 927

Post » Sat Jun 23, 2012 8:38 am

Moved to correct section.

"Help Wanted" is meant to be "Help for Hire" not, "Something doesn't work, please help" just for future reference.

Tired of crappy file hosts that are crappy? Get DROPBOX -
Posts: 2,853
Reputation: 25,966

Post » Sat Jun 23, 2012 1:53 pm

Well, for smooth character movement, since there isn't a nice way for doing WASD, I did the Key Is Pressed event, took the characters current position, and then added around 3.5 pixels to each part of the character, eh?
Posts: 45
Reputation: 2,984

Return to How do I....?

Who is online

Users browsing this forum: el3um4s, MrWhizm, orangemicro, qFrct, Quellquun, rtkiii, SnipG and 2 guests