Dropping a Chest on Random Coords Every Hour?

Discussion in 'Plugin Development' started by Booshayy, Mar 25, 2014.

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

    Booshayy

    So I want to drop like a "care package" (a chest filled with random items) on a random location every hour on the dot. How would I go about doing this?
     
  2. Offline

    TehVoyager

    What have you tried already?
     
  3. Booshayy
    This is very simple. Use the Random class to generate random x, y, and z coordinates and then set the block in that location to a chest. Then, get the inventory of the chest and set the contents to whatever you want. As for doing it every hour, simply schedule a syncRepeatingTask() and set the time to 72,000 ticks
     
    Mattkx4 likes this.
  4. Offline

    Booshayy



    Thank you very much. It's much appreciated!
     
    The Gaming Grunts likes this.
  5. Offline

    LupeKid

    it would be great if someone could make a plug in for this :D i would love this
     
Thread Status:
Not open for further replies.

Share This Page