Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length

 
Advanced search

1375222 Posts in 65096 Topics- by 57351 Members - Latest Member: SSoft_boi

April 07, 2020, 10:10:59 PM

Need hosting? Check out Digital Ocean
(more details in this thread)
TIGSource ForumsDeveloperTechnical (Moderator: ThemsAllTook)Rotation jitter - impulse based collision
Pages: [1]
Print
Author Topic: Rotation jitter - impulse based collision  (Read 534 times)
zarovv
Level 0
**


View Profile
« on: February 14, 2020, 11:03:32 AM »

Hi.
I asked in the past about an issue i was having with collision and i was suggested to try out impulse based collision response.

I tried it and it works pretty okayish, but i have some annoying problem of collision jitter.

Basically, when i push the cube in down direction it jitters right and left non-stop.
It just rotate right,left,right and doesn't seem to slow down, stop and align with the ground.

Someone knows or have a clue on how to handle it?




Sorry that i bother with a lot of questions. its just this community seems to be responsive and very helpful )
Logged
qMopey
Level 5
*****


View Profile WWW
« Reply #1 on: February 14, 2020, 08:44:50 PM »

Your best bet is to learn from a resource that already works. For example, Box2D Lite (this is the Lite version, not actual Box2D, it's just a tiny demo to learn from). That way you can compare your code to it. Box2D Lite has a sophisticated solver that solves multiple collision points simultaneously to avoid jitter. https://github.com/erincatto/box2d-lite

If you want something even easier to understand, without the sophisticated solver, just some naive impulses, there is also this one: https://github.com/RandyGaul/ImpulseEngine



Logged
buto
Level 0
**



View Profile WWW
« Reply #2 on: March 06, 2020, 11:48:25 AM »

Maybe a little late... just wanted to say that the demo looks super cool!
Logged

Pages: [1]
Print
Jump to:  

Theme orange-lt created by panic