6
\$\begingroup\$

I remember back in the 90s when X-Com came out, being really impressed by the way its world map was an actual world: a map of Earth drawn on a spherical surface. That was pretty cool, because I had never seen it before. And now, thinking back... I can't recall just off the top of my head ever seeing it again, with the obvious exception of X-Com: Terror From The Deep, which used the same engine.

Most games that have an entire-planet world map either use a rectangle that wraps around at the sides but not the top and bottom (a cylinder), or a rectangle that wraps around at all four edges (an impossible geometry that some people call a "torus", even though it can't actually represent a real torus.) And that makes me wonder why.

What difficulties does attempting to build a spherical world map for a video game raise, that it's so incredibly rare to actually see it done?

\$\endgroup\$
4
  • 2
    \$\begingroup\$ Just as an aside, I'm curious why you say that a rectangle wrapping side to side and top to bottom "can't actually represent a real torus" - is it because there's some stretching involved in this map projection (like most map projections), or something else? \$\endgroup\$
    – DMGregory
    Commented Oct 20, 2018 at 23:08
  • \$\begingroup\$ @DMGregory On a real torus, the inner circumference is smaller than the outer circumference, significantly so if the thickness is non-trivial (or, in this case, if the width of the rectangle is similar to the height, which it usually is.) There's no way to turn a rectangle into that, whereas you can trivially wrap a rectangle around a cylinder and make it work. \$\endgroup\$ Commented Oct 20, 2018 at 23:25
  • 2
    \$\begingroup\$ The same goes for any cylindrical projection of a sphere — the circumference of a line of latitude should get smaller as we approach the poles, but in many common map projections we use for the Earth (including Equirectangular or the Mercator projections popular in mapping apps like Google Maps) they're drawn all the same width. That doesn't mean they no longer correspond to the actual Earth, just that the correspondence function involves a variable scaling factor. \$\endgroup\$
    – DMGregory
    Commented Oct 20, 2018 at 23:29
  • \$\begingroup\$ @DMGregory Sure, but in-game, in game-mechanical terms, no such scaling factor ever appears. For example, in the Civilization games, it takes just as many turns for a unit to circumnavigate the poles as the equator. Likewise, in a Final Fantasy game where the map wraps along both edges, the amount of time it takes to fly around the world on your airship remains constant no matter what latitude or longitude you're at. (Also, if it were an actual torus, there would be places where you would look up and see land. This never happens.) Therefore, impossible geometry, not a real torus. \$\endgroup\$ Commented Oct 20, 2018 at 23:53

1 Answer 1

12
\$\begingroup\$

Because spherical maps, compared to rectangular ones, create a lot of additional complexities regarding the technical implementation and the UI design while usually offering very little gameplay advantage.

First, there is the technical problem. With a rectangular map, you just use a 2-dimensional array to represent map positions. But unfortunately there is no proper way to map a 2-dimensional plane to a 3-dimensional sphere. So if you want your world to be tile-based, then that is usually incompatible with a spherical world (unless you are willing to accept some weird artifacts). And even if your game mechanics are not based on tiles: common tasks which are trivial on a plane, like measuring distances, calculating angles or detecting collisions between geometrical shapes, become a lot more complex when you are doing them in a spherical coordinate system.

The science of doing geometry on curved surfaces is called Non-Euclidean Geometry. If you want to dive deeper into the mathematical details, then this would be the search term to start your research with. But be warned: It drove various mathematicians crazy for over a millennium.

Then there are the UI problems. There is no good way to show the player the whole globe at once. The player can only see half of the game world at a time, and everything near the edges becomes distorted. Also, globes are difficult to navigate. If you let the player rotate the globe around the world axis', you encounter gimbal lock around the poles, which results in very awkward controls. If you let the player rotate the globe relative to their viewport, then the globe will end up in strange orientations and the player gets disoriented. A plane is usually far more intuitive for the player.

This UI problem is so prevalent that even real-world applications where it is important to remember that the Earth is round still often decide to visualize the Earth as a distorted plane instead. Like NASA mission control software, for example.

But dealing with those complications would be worth it if a spherical game world has a notable advantage over a rectangular one. But there are very few game concepts where the shape of the world would make a big difference.

If you wonder if the game you are designing right now should have a truly spherical map or if a planar map would suffice, ask yourself this: Do you have any game-mechanical reason besides "realism" why you want the map to be a sphere? If you can't think of any important game mechanic which would require a sphere and couldn't work on a plane, then do yourself a favor and don't torture yourself with trying to pull this off.

\$\endgroup\$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .