# Making a "planet" that you can circumnavigate

This topic is 4666 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

I'm researching the possibility of making a game world that emulates the size and shape of a planet. The player should be able to circumnavigate the planet. I have been looking into a few methods, the most promising method so far seems to be the "grid" method where there is a set number of grids, and when you get to one end of the grid you start back at the beginning. From what I've read, this will (mathematically) create the shape of a torus. Unfortunately this will not be a real planet so we won't be able to come in from space and land on the surface. I am also concerned that it will not feel like you're actually on a planet. I have seen a few examples of actual planets on here (www.there.com) and another project that I can't remember. PlanetSide seems to get away with this as well. What are some ways this problem can be solved?

##### Share on other sites
About a year ago I wrote a 2D overhead game where you navigated the ocean. I simulated an infinite expanse of water by having a grid of 9 cells arranged in a square, the center cell aligning initially with the monitor.

When you moved upwards, the entire grid went downwards, and the bottom row would eventually shift up to the top. Likewise for all the other cardinal directions.

I would think you could do something similar with a 3D terrain map or something similar (assuming it would tile seamlessly).

##### Share on other sites
That is what I was getting at with the grid method. Unfortunately with this method the size around the equator would be the same as the size around poles (unless I am mistaken).

##### Share on other sites
Do you think anyone would notice that the poles and the equator are the same size? Also, what if the grid sizes where the poles are were just "smaller?"

##### Share on other sites
You can do like this project...

Infinity

[Edited by - Shannon Barber on January 11, 2006 6:25:09 PM]

##### Share on other sites
I saw his work, it is amazing. Unfortunately he doesn't document how he achieves this magic :)

##### Share on other sites
Quote:
 Original post by cvg_jamesI saw his work, it is amazing. Unfortunately he doesn't document how he achieves this magic :)

Check out his journal. I don't think he goes too deep, but he is definstely willing to explain his implementation.

##### Share on other sites
Quote:
 Original post by cvg_jamesDo you think anyone would notice that the poles and the equator are the same size? Also, what if the grid sizes where the poles are were just "smaller?"

Well, it would of course depend on how close up the player generally sees the world. If it's from a perspective like in PlanetSide (i.e., from the view of a person on the planet), then I seriously doubt anyone is pedantic (and observant) enough to determine the discrepancy.

You might look at some Civilization IV screenshots. Of course I can only speculate as to how they do all of their stuff, but it appears they use the grid method when you are zoomed in far enough for the earth to appear flat, but when zoomed out further, they actually go so far as to map everything onto a sphere (except for the poles, which they simply cover with ice).

##### Share on other sites
You said you tried the "grid" method. However that would work if your planet was a cube or something (rectangular grid). If you search for sphere tesselation (or sphere generation or something) you could use each individual triangle (or square) as a subgrid, and it would look closer to a sphere. You can also try another generated primitive like a tetrahedron.

You can also use a grid in ellipse form with the width being twice the size of the height. This way it would look like an unwrapped sphere. Hope this helps,

JVFF

##### Share on other sites
With the grid method, I'm assuming we'll be running into floating point accuracy problems once we get very far from the origin, so we'll be implementing something along the lines of what was described in the Dungeon Siege article on Gamasutra where we keep all coordinates reletive to the local grid we're in. This will eliminate a global coordinate system. I would imagine this would make things like AI pathfinding very difficult and sending a player to a specific part of the world nearly impossible (unless we can come up with a way to send people to specific coordinates inside a specific grid (I say specific a lot ;) ).

If anyone has any ideas on the problems I just listed I would appreciate any insight you may have!

1. 1
Rutin
38
2. 2
3. 3
4. 4
5. 5

• 11
• 10
• 13
• 104
• 11
• ### Forum Statistics

• Total Topics
632977
• Total Posts
3009677
• ### Who's Online (See full list)

There are no registered users currently online

×