Re-routing with curves ??
Hi !!
Please Guys (sorry for my bad english), i''m making a game where i have a 3d map. In this map some units are able to move into.
So, consider this situation:
A unit is moving from point A (start point) and point B (target).
But, Before the unit arrives to point B, target i redefined as point C (obviously different to B).
How can i make the unit change its direction "steering" (tracing an immaginary curve, not a angle) ??
I tried with Bezier''s curves, but they''re too difficult to implement. Does exist a faster and easier solution ?
Please, write every advice you know about it.
Thanks !!
//-------------
Making Funny Fake Codes
//-------------
//-------------A straight line may be the shortest distance between two points, but it is by no means the most interesting.http://members.xoom.it/NinjaCross
What you are refering to is known as ''non-holonomic'' motion planning. It''s like driving a car, you can''t just reverse direction and maintain the same speed. Therefore you have to implement some kind of physics model in your game, using the mass of your object, its current speed and stuff to calculate the curve it needs to make to reach that point. This can be kind of tricky though since it involves quite complicated math.
You might find more info at http://www.laas.fr/~sleroy/
******************************
Stefan Baert
On the day we create intelligence and consciousness, mankind becomes God.
On the day we create intelligence and consciousness, mankind becomes obsolete...
******************************
You might find more info at http://www.laas.fr/~sleroy/
******************************
Stefan Baert
On the day we create intelligence and consciousness, mankind becomes God.
On the day we create intelligence and consciousness, mankind becomes obsolete...
******************************
******************************StrategicAllianceOn the day we create intelligence and consciousness, mankind becomes God.On the day we create intelligence and consciousness, mankind becomes obsolete...******************************
Thanks StrategicAlliance, your help was very useful !
//-------------
Making Funny Fake Codes
//-------------
//-------------
Making Funny Fake Codes
//-------------
//-------------A straight line may be the shortest distance between two points, but it is by no means the most interesting.http://members.xoom.it/NinjaCross
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement