Page 1 of 1

What is the Best Way To Animate a Car on a race track ? Bezi

PostPosted: 12/9/2017, 1:41 pm
by molgat
Hi Everyone,

I have been tring to animate the position of the car - which is a group null - created with Element 3d.

But, creating the 3D path with bezier key frames is very time consuming.

is there a better way to move the car along the race track - ?

Desperately seracing for an answer for a loong time ☺

Thanks in advance,

Tolga


p.s. here below I attach the pic of the 3d model of the race track

https://www.dropbox.com/s/zxinaxgqr1lej ... 0.png?dl=0

Re: What is the Best Way To Animate a Car on a race track ? Bezi

PostPosted: 02/20/2018, 10:53 pm
by punamjaisawal
In most endless racing/running games, the world moves not the player and camera. If you want turns, it would be a lot more complicated because the world has to rotate. In pseudocode, I would do this:

var road : GameObject; var speed : float;

function Update(){

road.instantiate(in front of player);
road.transform.position(0,0,speed * time.deltatime);

if(the road object get behind the player){
road.removeFromScene;
}

}