Jump to content

Creating and unfolding a sphere


deathruler

Recommended Posts

Hello guys,

I've had trouble with creating a sphere, and then i need to unfold it, and make a chart out of it.

What I'm trying to do, is a little hard to explain, but I'll do my very best.

 

I'm trying to create a game, and when a user registers with the game, he must be assigned to a planet.

That planet should exist of land, water, rocks, trees, etc..

 

A planets index:

What I'm trying to do is split the planet to squares, witch would hold the actual player size.

So, players, water, rocks, trees take 1 spot of the planets size.

So lets say, if the planet got 200 land marks, 200 players can be on the planet.

But if the planet got 1 square water, and 1 square rocks, 198 players can be on the planet.

So basically, I'm trying to generate a number from a random diameter, which tells me how much space the planet has.

 

From a sphere to a map:

Basically what happens if you convert Earth to a map, you'll get this.

And that, is what I'm trying to create.

That image, should be generated by a diameter i give a function and split into spaces which will be the spots.

Now the planet does not need to have a perfect hyperbole, but it should look like it.

 

Example: http://img242.imageshack.us/img242/968/worldmo1.png

 

The red lines, and squares you see will be the index.

But only full blue squares ( brown ) will be a spot which a player can own.

The red crosses, are not fully blue spots, and shouldn't exist and remain black like the rest.

So eventually you'll end up with a squary 2 sided hyperbole.

 

Now, the reason i posted this is because my skills in sphereology ( math in spheres ) is none.

I just don't know how to flatten a sphere to a map, and decide which spots should be land, and the other ones empty.

Can someone help me with the formula's, and the way i should do it after that point.

 

I'm good with php, don't get me wrong, but this kind of math is just to much for me.

 

 

 

 

 

 

 

 

 

 

 

Link to comment
Share on other sites

I already read that, but that doesn't explain show the formula's needed to do this.

And as i said, my math isn't good with these shapes.

 

My native language is also Dutch, and as you read through this map projection tutorial, the English used in that is much to hard for me.

When i read it, i spend most of the time converting words from English to Dutch, and still not understand what their saying in it.

There is a tutorial like that on wiki in Dutch ( kaartprojectie ), But that one isn't good.

 

That is why i came here, perhaps there is someone who would like to explain step by step how to do it.

 

And for those who see beyond the map projection option, the Robinson projection is what i prefer above the map projection.

Link to comment
Share on other sites

  • 4 weeks later...
This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.