[INACTIVE][FUN] EggTimer v1.1 - Timed Item Dropoffs [684]

Discussion in 'Inactive/Unsupported Plugins' started by SpaceManiac, Mar 24, 2011.

  1. Offline

    SpaceManiac

    EggTimer - Timed Item Dropoffs
    Version: v1.1
    Tested on: RB 684, likely to work on previous and later builds.

    Redskye on IRC requested this and I figured it'd be a quick plugin. I got all the coding done in one night a few days ago but didn't get a chance to test it due to being busy with schoolwork, but here it is now.

    EggTimer is a small Bukkit plugin to allow the creation of timed item dropoffs in chests around the map, for things like providing extra resources to factions who can hold a control point, allow easy grabbing of items on a creative server, loot in dungeons, and other situations.

    Features:
    • Works with Chests, Dispensers, and Furnaces (and automatically works with any future containers).
    • By default, chests are only updated if the chunk is already loaded. This is configurable (see below).
    • By default, chests are cleared before the first item is added. This is configurable (see below), and chests can also be cleared manually if global clearing is off.
    • Multiple items can be added to a chest - just specify the same chest multiple times in the locations file.
    • Items can be added in any amount, including amounts greater than 64 (in which case the items will spread over multiple slots).
    • Metadata for items can also be selected. For tools, this is the damage value, and for other items this is a value from 0-16 with meaning varying by type (most items should be left at 0).
    • Multiworld is supported and item spawn intervals are configurable down to the second.
    Known issues:
    • Double chests may act weird and so may Furnaces.
    Configuration:
    EggTimer's configuration is stored in plugins/EggTimer/locations.txt. Each line
    in the locations file can be one of these (or a blank line):

    #Comment
    $configOption=value
    world,x,y,z=item,count,data,interval

    Comments can be used so you don't forget what's what. Available configuration options are:

    $requireLoaded=true|false - Whether chunk must be loaded for items to be added.
    $clear=true|false - Whether to clear chest by default (use 0 as an item type to clear)

    On item stack lines, world is the name of the world, x, y and z are block coordinates, item is
    the id of the item, count is the amount, data is the metadata value, and
    interval is the number of seconds between the respawn of the item.

    OPs may use '/eggtimer reload' to reload the config file from in-game (Permissions support possibly coming soon).

    Downloads:
    Download: EggTimer v1.1
    Source code: GitHub (MIT License)

    Changelog:
    Version 1.1 (April 23)
    • Added configuration for requireLoaded and clear.
    • Added compatibility with all container objects.
    • Added ability to add multiple items to a chest.
    Version 1.0 (March 24)
    • Initial release.
     
  2. Offline

    Quizdonkey

    Oh sweet, I remember that request, goodjob
     
  3. Offline

    Crasha

    Can this be used to empty a chest periodically?
     
  4. Offline

    SpaceManiac

    @Crasha Hmm... not at the moment. You could add one dirt, but trying to add air can break stuff. I'll see about adding that.
     
  5. Offline

    Crasha

    That would be awesome because then i could use it together with RealShop to make a player to player 'market' chest that would empty itself every night or something like that.
     
  6. Offline

    Rhythmatic

    I don't see how this can be considered a "feature". It's VERY limiting. If I'm using this in a dungeon, and have it set to refill at a specific interval, and the people aren't in the dungeon when that interval occurs, it won't get refilled. This either A. discourages people from doing the dungeon, since the likelihood of getting something is low, or B. encourages people to sit around at the rewards of a dungeon. This feature should be, at minimum, toggle-able in the config file.
     
  7. Offline

    Teh Caveman Man

    Hi there,

    I love the idea for this mod- i'm actually running a PVP arena server, to make a long story short, and this mod is the perfect way to set class items.

    The only issue being, the plugin isn't finding the locations.txt file. I'm using bukkit build 612, and was wondering if there was a compatibility issue, or if the notepad isn't written correctly. The locations.txt is in the EggTimer_v10 folder. An example of the code so far is:

    pvp playtest map,-377,42,80=279,1,0,60
    pvp playtest map,-377,42,80=298,1,0,60
    pvp playtest map,-377,42,80=299,1,0,60
    pvp playtest map,-377,42,80=300,1,0,60
    pvp playtest map,-377,42,80=301,1,0,180
    pvp playtest map,-373,42,80=298,1,0,180
    pvp playtest map,-373,42,80=299,1,0,180
    pvp playtest map,-373,42,80=300,1,0,180
    pvp playtest map,-373,42,80=301,1,0,180
    pvp playtest map,-373,42,80=279,1,0,180

    is there any specific issues you can see with this? or is it supposed to be x=-377, etc?
     
  8. Offline

    SpaceManiac

    You could try renaming the jar "EggTimer.jar" and putting the locations.txt in "plugins/EggTimer/locations.txt" and see if that clears up any issues. The file itself looks fine.

    @Rhythmatic @Crasha should have time to work on this soon.
     
  9. Offline

    Teh Caveman Man


    Everything works now...I can't thank you enough! This mod is awesome! I'll keep you posted on how it all works in our play-testing phase.
     
  10. Offline

    DuneTrader

    I wish you would update this for 617, I had this great idea for my server for players to buy NPC workers, and these chests would generate the goods the NPCs would get each day
     
  11. Offline

    tr0y

    Awesome.
    Can this be done to dispensers as well?
     
  12. Offline

    SpaceManiac

    @Crasha @Rhythmatic @DuneTrader @tr0y Finally got a chance to update this. 1.1 is in the original post and should fix all your grievances. Enjoy. :D
     
    tr0y likes this.
  13. Offline

    Plague

    cb 684 - inactive
     
  14. Offline

    killerx243

    Anyone know if there is there any mods like this one for a newer version of bukkit?
     
  15. Offline

    zhuowei

    This still works with CraftBukkit 1337.
     
  16. Offline

    killerx243

    Except for what we want to use it for the config thing would be a bit annoying. We want to put a chest in each production building, so a cow farm gets set up and every day it spawns milk and beef spawn.
     

Share This Page