Varying longitude and latitude
dexman545 opened this issue ยท 7 comments
Hello, I was wondering if it would be possible to make longitude/latitude vary based upon the players position. Personally, I think it would be a very awesome thing to have, and would add a lot to the depth of the mod. I have figured out the calculations for converting player coords to degrees, based on TerraFirmaCrafts system, and the system they provided on their wiki (z=0 is the equator, +/- 30000 is the arctic circle. http://wiki.terrafirmacraft.com/Coordinates I also used TFC because a) it has a very good system for figuring climes that works well with MC, and b) I use it in a modpack for 1.7 with stellar sky).
Lattitude:
(((Z / -1,000) * 250) / 10,002) * 90 = Degrees North.
Simplified: Z * 0.0022495501 = Degrees North
Longitude:
(((X / -1,000) * 250) / 10,002) * -90 = Degrees East.
Simplified: X * 0.0022495501 = Degrees East
Thank you,
Dex
yes, but since the mod is client-side only, can't the celestial angle be updated periodically, and the skybox redrawn? It wouldn't even have to be updated every block traveled by the player....every 500 blocks translates to about a 1.1 degree shift, so the calculation only really needs to occur when the player crosses that 500 (or 1000) block boundary, and even then, the angular differences aren't all that small to cause major visual differences. Using the 1000 block example, if the player is within 500 blocks to the main line (say, 2000), then the calculation will only be done for the 2000 coord, until they are more than 500 blocks away (2501), at which point it then uses the calc for the 3000 coord. This creates bands of 1000 block width where all players in that band have the same skybox, but those outside that band have a different one.
This mod is not only for SSP, but also SMP. On SMP if celestial angle differs on client, one will see mobs spawning on day because it is day on server.
So both the longitude, and the latitude change the time? IRL, timezones are dependent on longitude, and run pole to pole, or is this function in simulation of something else?