Hot answers tagged

21

There's an excellent article out there that explains the 3D rendering of these games in detail. And you'll also find a complete implementation in JavaScript here. The basic idea is as follows: You divide your screen into a number of strips and use perspective-projection to calculate the texture-coordinates (scaling and y position inside the road-texture) ...


15

The accumulation of nitrious oxide in games has no real life counterpart. In real cars a limited number of capsules filled with NO2 have to be filled at the start of the race. In that way it is similar to fuel which you can't 'earn' during a race (except for a pitstop ofcourse). The reason this mechanic in games exist is to encourage risk-reward gameplay. ...


10

The "slow-down from the collision" has always been enough to discourage me from driving carelessly in racing games. If you hit a wall head-on, you're immediately at a dead stop. You'll be passed by any cars that were within 10-20 sec of you, depending how many seconds it takes your car to get back up to speed once you're positioned back onto the track. ...


10

In cinema, photography and game design, it's fairly common-held knowledge that certain type of perspective and movement can cause objects to seem out of scale with each other, or simply to receive less attention from the viewer. The solution to such a problem is to play with scale empirically until things "look right". I've not heard of an exact formula or ...


10

It depends on the level of detail you go into and how you generate your data. From Will's post, deriving your layout from OSM does seem to be a way of doing this to an extent, however if you derive anything from any other source you'll need to carefully check their licences very carefully. There may be certain buildings or objects in real cities or ...


10

Shawn Hargreaves describes how MotoGP used a special track-relative position system. Ignoring the vertical y position, the x/z Cartesian coordinates are translated to a track-relative system. This had many benefits for calculations involving the relative positions of participants in a racing game (for example for the AI): A common simplification is to ...


9

This blog has four links (the third is broken), the first of which seems like an amazing resource, the others seem pretty great too. I'm probably going to read over this just for funsies, should be a good read. You could take a look at the Rigs of Rods engine, it's an open source soft-body vehicule simulator, it may give you some insight into how it's done, ...


8

You can use OpenStreetMap.org - their license is clear and suitable: You are free to copy, distribute, transmit and adapt our maps and data, as long as you credit OpenStreetMap and its contributors. osm2xp is for example using this data for the X-Plane game:


7

Build a mock up and run through your environment just to see what it feels like. Build several tests, try them all. You can't blindly use rules from someone else when it comes to making YOUR game feel good, there is only testing with players and iteration. You could use someone else's rule of thumb to build one of your tests, of course. Maybe later, ...


7

1) Assumes that both objects are moving on the same line - (this is explained in the wikipedia page you linked) your conclusion is correct, in this situation, with constant velocities, the frequency shift is constant. For the frequency shift to change, the relative velocities need to change, hence formula 2), for the situation where Vs is constant but not ...


6

One solution would be to cheat a bit and guess what the player wants to do. When the player is on a straight section and presses left, you can assume that he wants to switch lanes. When he is close to a curve or intersection, he certainly wants to turn. The player is unable to control it's exact steering angle in a curve, so you could decide to give the ...


6

Vector : Vectors describe the magnitude and direction. If you just want the direction you simply normalize it. This causes the vector to shrink to fit into the unit circle. Meaning that it has magnitude/length of 1. From rotation angles: To get the x and y components for your direction: //(pi/180) - > degrees to radians. (180/pi) - > radians to ...


5

Your own proposed answer is spot on; to determine the finish time for a car, you take its position on the frame before finishing and its position on the frame after finishing, and determine at what point during that frame it actually crossed the finish line. If (for example) it crossed the finish line at 40% of the way from its previous position to its ...


5

I'm not sure what language you are working in but there is a procedural mesh extrusion example for Unity3D located here: http://unity3d.com/support/resources/example-projects/procedural-examples I'm sure you could look at the code and rework it for your situation. EDIT: I'm working on a game that uses a procedural extruded rail system like the one you ...


5

It really depends on what you want your game to "feel" like. You could go with the Micro Machines method of using a tilemap to generate the track. However, if I were you I'd go with the "cool" solution: a spline. First, you should realize that a spline is nothing but a set of points. It has a beginning and an end. A straight line is a form of spline. ...


5

First of all, i'm sorry for any gramar erros. English is not my first language. feel free to edit my answer if you find it necessary. In my oppinion, you have to consider the type of game you are trying to create. If you are making a game more similar to reality, slowing the speed of the car and and screw it up a bit would make the gameplay more fun and ...


5

Personally I don't think there's that much special about racing games that makes them that specific to choose engines for. I would think that things like cost, language, platforms, art pipeline, etc. are more relevant to the topic at hand. Since there are at least a dozen "what engine should I use for game type X" questions out there I'm not going to ...


4

I will take part in your survey :) What is the way it is done in your favorite racing game? I prefer when the car is slowed down or stopped and damage is applied to the car. After enough damage, the car's handling or top speed is reduced. How is it done in other successful racing games? I don't play a lot of racing games, but the ones I'm ...


4

I would suggest something you haven't listed. Don't "create" your track at all. Rather, define it indirectly by placing a bunch of collide-able objects around where you want your track to be. Walls, old cars, wrecked buildings, semi-transparent-laser-beams... whatever you want. Heck, they don't even have to be visible. Then you can do your collision ...


4

http://www.gametrailers.com/video/expanding-horizons-dark-sector/29795 I remerber hearing about this before. Check minute 1:50 (Things next to you need to be 1:1 scale and as things become further away the need to be scaled up).The guy also mentions that the developers of max payne also talked about this issue maybe you could look that up. Of course they ...


4

What I'd try would be: Multiply the car's velocity by some constant Δt and add it to its location. (That is, calculate what the car's location would be Δt time steps in the future if its velocity remained constant.) Call this the target point. Have the camera chase the target point in some natural manner. A simple way to do this would be to ...


4

Fundamentally, braking assist works comparing the player's car's speed against the speed of the nearest point on the track's optimal racing line, and automatically applying the brakes as needed to bring the player's car's velocity down to match the speed specified on the optimal racing line. It's exactly like writing racing car AI, but only applying the ...


4

I am not a lawyer, for actual legal advise consult an actual lawyer. No, you can not have licensed cars without a license, and you probably won't be able to get one regardless. Car licenses are expensive, hard to come by and fraught with extra requirements (ever wonder why you generally won't get a Ferrari in a game with destructible cars?). Releasing a ...


4

Usual disclaimer: I am not a lawyer and in this site questions about these issues have to be always taken as ideas, thoughts or experiences, never as technical advice. That said, yes, if you or somebody from the developer team wants to use the names of the cars, the names of the car companies or the models of the cars, a license will be needed. Otherwise, ...


3

For 3D games, usually you implement two tracks : one with very basic level of detail (just a floor and 2 walls) that you use to compute the collisions and physics. Then you add another data, probably with different LODs for rendering, that you can load as the player advances. Also if your game stays basic, meaning you keep the same width along the whole ...


3

Although Bezier curves are the usual thing people go for, I'd recommend considering circular arcs (and maybe elliptical arcs) unless you really need Bezier curves or splines: It's nice to be able to evenly space things along the curve. For example you might want to draw lane markers or you might want to calculate a path in curve coordinates. A ...


3

This started as a comment, but got too long. :) If by "realistic", you mean including weight transfer back/front or left/right when accelerating/braking/turning, you need a 3d-model for the car it self (since there will be forces & rotation around three axis), even if it runs on a flat 2d surface. Thus using a 3d-model might be the only way to get what ...


3

If you want to just get something reasonable going, I can't more heartily recommend the talk http://video.google.com/videoplay?docid=4776766805683353325 by the physics programmer on rallycross. (a shipped game on the PS1 back in 1997, so it's very quick on modern hardware and arguably implementable in higher level languages that aren't as efficient at math ...


3

I can you change speed in some non-linear algorithm like : if(userinput == move_faster) if(maxSpeed/2 - oldSpeed/2 <= maximum_acceleration) newspeed = (oldspeed + maxSpeed) / 2; else newspeed = oldSpeed + maximum_acceleration; else if (userinput == stop_move) newspeed = oldspeed - someValue; else newspeed = ...



Only top voted, non community-wiki answers of a minimum length are eligible