The Daily Click ::. Forums ::. Klik Coding Help ::. Smooth collision
 

Post Reply  Post Oekaki 
 

Posted By Message

Jarzka



Registered
  26/12/2003
Points
  270

VIP Member
11th June, 2007 at 13:16:17 -

So is there any easy way to make smooth collision to the Race Car Movement? I mean if it touches the wall and I use "stop", the object just "shakes" and goes some pixles back and then does it again when touches the wall.

I found one tutorial here, but I won't like to make four another objects around the main object.

 
n/a

DeadmanDines

Best Article Writer

Registered
  27/04/2006
Points
  4758
11th June, 2007 at 17:05:39 -

I've never tried it, but it could be interesting to try using particles. If you imagine particles hitting the wall, they would hit and bounce at different times.

If you could find a way to bind particles loosely to the car (or rather, bind the car to the particles), you could potentially cause it to rotate on impacts and all sorts.

Eg. If you have a particle for the front and a particle for the back. The car hits a wall at an angle. The front particle hits the wall first, followed by the back particle. We then make the car follow that same kind of path, so it rotates. The result would be that the front hits the wall, and the weight of the rear brings the back sliding into the wall as well.

Could be worthing experimenting with...

 
191 / 9999 * 7 + 191 * 7

BROO



Registered
  31/10/2002
Points
  595
12th June, 2007 at 07:13:19 -

Idea for simple model:

Like DeadmanDines said... you need a lot of particles located on the border of car (or one object which walks throught the whole border with Fast Loop). Each of them must contain information about its location relative to the center of mass.

And then do some calculation in notebooks to find out mathematical formula which gives you answer about new speed, acceleration, angular speed and angular acceleration dependent on which point collided with obstalce and what was the speed, acceleration, angular speed and angular acceleration before hitting obstacle.

It is really hard and boring work :---(. Ask Joe., he claims to be good in this stuff :---).

 
n/a

Hagar

Administrator
Old klik fart

Registered
  20/02/2002
Points
  1713

You've Been Circy'd!Teddy Bear
15th June, 2007 at 07:32:51 -

This is where i differ from some people on here. Is it worth going through pages of derivation to get this 100% accurate?

IMHO no, but some people will.

 
n/a

BROO



Registered
  31/10/2002
Points
  595
15th June, 2007 at 07:46:48 -

Some people aren't experienced enough to guess quite nice formulae for collisions. That's why I'd rather do some calculation to find out which parametres influences on results before making collision algorithm.

Good physics is the most important thing in racing games.

 
n/a

Eternal Man [EE]

Pitied the FOO

Registered
  18/01/2007
Points
  2976

Game of the Week WinnerHero of TimeLOL SignI am an April Fool
19th June, 2007 at 17:50:26 -

Why would you introduce something as advanced as particle collision to a guy who doesn't like the idea of putting four new objects i.e detectors around the car?
I really like the idea of a particle collision test though.

 
Eternal Entertainment's Code'n'Art Man

E_E = All Indie


...actually Ell Endie, but whatever.
Image
Image
   

Post Reply



 



Advertisement

Worth A Click