Appropriate World Scale for FPS Game

Started by
1 comment, last by Krohm 10 years, 10 months ago

Hi,

I'm not quite sure about how the world scale should be, so I want to know:

- What is the appropriate player capsule size (width and height)?

btCapsuleShape* player = new btCapsuleShape(??, ??);

- What the appropriate gravity for bullet physics? Should I keep it 0, -10, 0? or should I change it?

- What is the appropriate near view and far view for projection?

The game is first person shooter game.

Advertisement

There is really no answer to this question. Some games use metres as units, e.g. a gravity of -10 means a downwards acceleration of 10 meters per second. Other games use inches or kilometres (or some other funky unit, depending on their needs). So it depends on what scale units you use in your game. For instance, your art assets might have the player have a bounding box of 0.5 x 0.5 x 1. But 0.5 of what? Perhaps the player is a giant, in this case maybe this should be kilometres. Perhaps it's an ant, and then it should be millimetres. Or maybe it's just a generic soldier, so it probably stands for half a metre. Scale accordingly.

I'm inclined to think that for an FPS you should just follow the rule of using SI units (metres, seconds) as a base unit for your graphics/physics values to make it clearer, so that you know that your world terrain is exactly 2km by 5km and your player is 1.85 metres tall and so on instead of having to convert back and forth across different scales, but it's up to you. As long as you scale everything consistently it will look the same anyway at the end of the day (barring floating-point issues if you use ridiculous scales which you shouldn't anyway)

In other words, it doesn't matter, as long as you are consistent and that your assets are properly loaded in the engine. There may be issues using normal scales if you are rendering a very large or a very small world, but I don't think this will be a problem here.

“If I understand the standard right it is legal and safe to do this but the resulting value could be anything.”

Keep in mind that Bullet needs the physics representations to match its internal scale (check out "scaling the world" in the manual) otherwise things will look super heavy or slow-motion.

In this perspective, it makes sense to have 1.0 being 1 meter and 5000 being 5 km. But of course this is not always viable.

Previously "Krohm"

This topic is closed to new replies.

Advertisement