[solved] get moon phases!

Discussion in 'Plugin Development' started by MG127, Dec 19, 2011.

Thread Status:
Not open for further replies.
  1. Offline

    MG127

    is there a way to read out what moon phase is?
     
  2. Offline

    user_43347

    It's client side I believe, so I doubt there is a way.
     
  3. Offline

    MG127

    i thought that everyone on the server has the same phase
     
  4. Offline

    user_43347

    They do, but the images and clock for it are internally controlled in the client, and make sure to reply and not just comment.
     
  5. Offline

    MG127

    but if they do, there has to be some kind of controller on server side
     
  6. Offline

    user_43347

    For example, all sounds are client side, they simply send packets for them, weather, can also be client-side only, you'd be surprised at what is actually handled on the client-side.
     
  7. Offline

    nisovin

    My guess would be that it's based on world.getFullTime().
     
    MG127, flowwolf0 and Bone008 like this.
  8. Offline

    MG127

    it seems to be like this
    days=world.getFullTime/24000;
    phase=days%8;
    phase==0 -> full moon
    phase==4 -> new moon
     
  9. Offline

    Chiller

    Great theory!
     
  10. Offline

    vsams14

    Realize this was from a while back, but this is indeed how moon phases are calculated. Adding/subtracting 24000 to fulltime will change the phase by 1.
     
Thread Status:
Not open for further replies.

Share This Page