World Scale

Dec 8, 2007 at 9:16 PM
We should define a world scale for the project, and put into a design document, or requirement document.

I believe our scale should be 1 unit : 1 meter. Meters are simple, and I get the feeling Shaw will use them for physics, as physics equations are usually done in meters.

So if our terrain is 1024x1024 then it is 1024 meters by 1024 meters (1024 sq. meters). This would allow us a constant scale for models as well. If we put a 6ft tall character in the game, and laid him down on the ground, he'd better take up about 2 units in the world. If a designer requested a 100ft giant cyclops as a boss, the artist knows to make it about 33 units tall in their modeler to get the proper outcome in the engine.

It allows for other things to be easier as well. If I want to aggro a bot at 50 feet, I can simply use about 15 units in the game. If I want to know my distance from something, I can check the length between them and know reliably that it is in meters. If I want to set the walking speed of a human character in game, I might as well set it to the average walking speed of a human in meters.

If I want to use a heightmap of the grand canyon to get a semi-accurate depiction in the engine, we should be able to set the terrain to respond such that if we say the maximum height is 500 meters (~1500ft) then a white pixel on the heightmap will end up at 500 units/meters in the game.

Finally, it has artistic benefits as well. If someone makes a brick wall in the game, and textures it. The UV coords for the wall brick texture should come out that the bricks are the same size in units as they would be in meters in the real world.

See where I'm going with this? It allows every measurement of size, distance, and speed in the game to have accurate measurements, and as such should give a more realistic world if people follow the system.
Dec 8, 2007 at 9:28 PM
This is something that should be decided on a game-by-game basis. To the engine, the only thing that matters is consistency. Whether one unit is one foot, one meter, or one light-year doesn't matter to the engine. When creating a game, you just need to assign values to physical constants for your scale (i.e. 9.81 for gravity if using 1 unit = 1 meter.) For the AI components, I would make the distances configurable so games can set their own values based on the world scale they are using.
Dec 8, 2007 at 10:41 PM
Shaw is right we should not impose this on the game devs, but I do expect that we should have a default implementation which is coorspondent to 1 meter per pixel.
Dec 8, 2007 at 10:45 PM
Very true, I guess we shouldn't impose meters on devs, however I think we should maintain a standard during development of the engine for our own purposes. This way when a dev chooses a scale, everything will fall into place for them.
Dec 9, 2007 at 1:07 AM
You mean 1 meter per unit, not pixel, right? :)
Dec 9, 2007 at 1:20 AM
Yup :) otherwise we get a very odd system :P