Top-down mini car race game

Get help using Construct 2

Post » Fri Nov 04, 2011 10:34 pm

Here's a little example I made http://dl.dropbox.com/u/1412774/cargame.capx.

It's a micromachine like game, where I want the car controlled by the computer to have a plausible behavior. I used a series of waypoint, but I can't get the physics to create a lifelike movement (I even have problem with the angle at the start of the game...)

I use to "dummy" object to store the values of the previous and next waypoint.

(and by the way, I don't own any rights for the image used as background, so don't use it for any commercial stuff, I can't give them to you !)Pode2011-11-04 22:37:41
B
33
S
9
G
6
Posts: 709
Reputation: 6,704

Post » Fri Nov 04, 2011 10:51 pm

It looks like your capx uses some non-standard behaviour - mind sharing which one?
B
19
S
6
G
6
Posts: 1,101
Reputation: 5,646

Post » Fri Nov 04, 2011 11:20 pm

@Somebody

You want THESE from rexrainbow.
If your vision so exceeds your ability, then look to something closer.
Moderator
B
120
S
28
G
68
Posts: 4,843
Reputation: 48,287

Post » Sat Nov 05, 2011 7:04 am

ok the forum ate my explanation ;_;

just take that and be appy
carAI.capx
Last edited by Yann on Sun Sep 14, 2014 11:01 pm, edited 1 time in total.
B
60
S
22
G
14
Posts: 1,479
Reputation: 16,346

Post » Sat Nov 05, 2011 3:47 pm

I don't know why, but the answer I gave to Yann was not displayed in the right thread...
So, I just said "@Yann : sorry for the explanation. Anyway, the feeling you gave to the car is great ! ".
I'm removing it from the other thread...
B
33
S
9
G
6
Posts: 709
Reputation: 6,704

Post » Sat Nov 05, 2011 5:47 pm

(: glad you like it, hope you understood how it works
B
60
S
22
G
14
Posts: 1,479
Reputation: 16,346

Post » Sat Nov 05, 2011 6:16 pm

If I understand well what you have done, you dissociate the angle of the car from the trajectory, by using "targets" above each waypoints.
The linear interpolation part is there to give a nicer movement profile for the car.
B
33
S
9
G
6
Posts: 709
Reputation: 6,704

Post » Sat Nov 05, 2011 6:18 pm

and the change of speed is important to avoid losing trajectoryYann2011-11-05 18:18:37
B
60
S
22
G
14
Posts: 1,479
Reputation: 16,346

Post » Sun Mar 18, 2012 7:00 am

wow this is simply amazing. I guess i have no excuse to not making a racing game. For the laps one could just add a variable that increases on every hit. 3 hits = race complete. But how would you calculate position. Like 1st, second, third?

The reason i ask is because last semester i was talking to my instructor on how hard would it be to make a racing game in UDK. He said it would be rather challenging. I think i could examine the AI and some how make the scorpian in UDK a competitive race enemy.

Good stuff.



B
22
S
5
G
3
Posts: 194
Reputation: 5,855

Post » Sun Mar 18, 2012 7:09 am

I also found an article on gamasutra explaining racing and track mechanics. Anyone can check it out if your interested. I think its pretty interesting. Before i read it i thought racing games weren't really planned design wise.

http://www.gamasutra.com/view/feature/134845/a_rational_approach_to_racing_game_.php

B
22
S
5
G
3
Posts: 194
Reputation: 5,855

Next

Return to How do I....?

Who is online

Users browsing this forum: 99Instances2Go, Google [Bot] and 21 guests