Inactive [RPG] PhatLoots v0.9.1 - Chests with randomly generated money/items [953]

Discussion in 'Inactive/Unsupported Plugins' started by Codisimus, Mar 19, 2011.

  1. Offline

    Codisimus

    This page will no longer be updated. Please follow this project at the Bukkit Dev Page

    PhatLoots - Chests with randomly generated money/items:
    Version: 0.9.1 (7/16/2011)
    Supports iConomy, BOSEconomy, Essentials, Permissions, LWC
    Download Page

    This plugin is a must for dungeons! Players open a linked chest and are rewarded with money (within a designated range) and randomly generated items that are predefined.

    Make a PhatLoot
    /loot make test
    Add some loot values
    /loot add test money 1 25 (looter will get 1-25 coins)
    /loot add test 322 1 10 (looter has 10% chance of getting a golden apple)
    Set a reset time
    /loot time test 1'6'45'30 (looter can loot the chest again after waiting
    1 day, 6 hours, 45 minutes, and 30 seconds.)
    Link a chest
    /loot link test (you must be targeting the chest you wish to link)

    Collective Loots allows you to setup a chest to give a certain amount (1 by default) of 'rare' items. So a chest may give the user a chance to loot a Gold Block (50%), Diamond Sword (30%), or Diamond ChestPlate (20%) yet the user will only get one of these items.

    Features:
    • Chests can give items, money, or both
    • Support for wools/dyes
    • Set different reward values for different chests.
    • Link multiple chests to one PhatLoot (this way you don't have to reenter all the items for every chest)
    • Player must wait a certain amount of time in order to loot the chest again (configurable)
    • Different reset times for each PhatLoot
    • AutoLoot option
    • Easily configure setting, loot values, reset times, and more
    • Make chests global (when looted by one person, everyone must wait to loot it again)
    • or user (each individual must wait the specified time between looting chests)
    • Uses iConomy, BOSEconomy or Essentials to give users money.
    • Uses LWC to auto protect PhatLoot chests (false by default)
    • Permissions to limit players from being rewarded and using commands
    • Included in CraftBukkitUpToDate for easy updating (make sure you come check the changelog if somthing is not working right)
    Save Files and Properties:
    Show Spoiler

    config.properties
    Code:
    #Tue Mar 29 14:04:05 EDT 2011
    // user - when a player loots a chest they must wait the specified time to loot again
    // global - when looted by one person, everyone must wait to loot it again (first person there gets the loot)
    DefaultResetType=user
    
    // if true, when you link a chest it will automatically make it public with LWC (so noone else can claim it)
    AutoLockPhatLootChestsWithLWC=false
    
    // default number of items you get from CollectiveLoots (only applies if CollectiveLoots is not blank)
    DefaultNumberOfCollectiveLootItemsRecieved=1
    
    // amount of time before the chest will reset "Days'Hours'Minutes'Seconds"
    // change to "never" in order for it to never reset
    DefaultResetTime=0'0'5'0
    
    phatloots.save
    Code:
    test1   // a list of all your Phat Loots by name
    test2
    
    test.properties
    Code:
    #Tue Mar 29 16:20:45 EDT 2011
    //the number of items you get from CollectiveLoots (only applies if CollectiveLoots is not blank)
    NumberOfCollectiveLootItemsRecieved=1
    
    // user - when a player loots a chest they must wait the specified time to loot again
    // global - when looted by one person, everyone must wait to loot it
    ResetType=user
    
    // list of linked chests (you should never have to edit this) "x,y,z,NameOfLooter,TimeLooted,_"
    Chests(RestrictedUsers)=-155,65,-93,Codisimus,88'16'13'16,_
    
    // "itemID,NumberOfItems,PercentOfLooting,_" Should add up to 100%
    CollectiveLoots=13,1,75,_14,1,10,_15,1,15,_
    
     // amount of time before the chest will reset "Days'Hours'Minutes'Seconds"
     // change to "never" in order for it to never reset
    ResetTime=0'0'0'20
    
    // "itemID,NumberOfItems,PercentOfLooting,_"
    IndividualLoots=money,0,2,_13,1,100,_14,1,23,_15,1,30,_
    


    Commands:
    • /loot make [Name] - Creates PhatLoot
    • /loot link [Name] - Links target chest with PhatLoot
    • /loot add coll[1-5] [Item] [Amount] [Percent] - Adds collective loot to target chest's PhatLoot
    • /loot add [Item] [Amount] [Percent] - Adds individual loot to target chest's PhatLoot
    • /loot add money [Low] [High] - Adds range of money that can be looted
    • /loot remove coll[1-5] [Item] [Amount] [Percent] - Removes collective loot from PhatLoot
    • /loot remove [Item] [Amount] [Percent] - Removes individual loot from PhatLoot
    • /loot unlink [Name] - Unlinks target chest with PhatLoot
    • /loot info [Name] - Lists info of PhatLoot
    • /loot name - Gives PhatLoot name of target chest
    • /loot reset [Name or all] - Resets PhatLoot restricted list
    • /loot delete [Name] - Deletes PhatLoot and unlinks chests
    • /loot list - Lists all PhatLoots
    Permission Nodes:
    • phatloots.use - Needed for group/player to receive loots
    • phatloots.info
    • phatloots.name
    • phatloots.make
    • phatloots.list
    • phatloots.admin.reset

    Changelog:
    Old Versions, ChangeLog, + Source can be found at Download Page
    Show Spoiler

    Version 0.9.1 (7/16/2011)
    • Added color support for all customizable messages
    • Fixed Collective loots
    Version 0.9 (6/26/2011)
    • Improved OP options
    • Updated Economy support
    • Added AutoLoot option
    • Improved add command
    • Added targeting chests for adding loot
    • Added item name support (rather than item ID)
    • Added saftey check so you can't add invalid loots
    Version 0.8.1 (6/13/2011)
    • Fixed OP permissions
    Version 0.8 (6/12/2011)
    • Cleaned up code/fixed errors
    • Added map support
    Version 0.7.4 (6/4/2011)
    • Cleaned up errors and added error messages
    Version 0.7.3 (6/3/2011)
    • Various fixes and code cleanup
    Version 0.7.2 (6/3/2011)
    • Added Essentials econ support
    Version 0.7.1 (5/4/2011)
    • Updated to iConomy 5
    • Few various fixes
    Version 0.7 (4/29/2011)
    • Fixed save/loss of data errors
    • Added support for wools/dyes
    • Fixed Double Chest errors
    • Added in game command for setting timer restriction
    • Added in game command for setting collective loots
    • Added option of multiple collective loots
    • Added option for setting resetType to Interval
    • Added prevention from looting out of ID-range items
    • Fixed delete command
    Version 0.6 (3/31/2011)
    • Fixed issue with users with "_" in name
    • Improved multiworld support
    • Fixed various bugs
    Version 0.5.1 (3/31/2011)
    • Fixed CollectiveLoots
    • Works with build #612
    Version 0.5 (3/30/2011)
    • Updated to craftbukkit build #602
    Version 0.4 (3/29/2011)
    • Redid save format
    • Added config file
    • Added double chest support
    • Added Collective loots
    • Added Auto protection using LWC (false by default)
    • Added a reset time ("Days'Hours'Minutes'Seconds" or "never") (0'0'5'0 by default)
    • Added global/user restriction (user by default)
    • Added antigrief feature, if chest is full PhatLoots will make room for new loot
    Version 0.3 (3/26/2011)
    • Added block protection for PhatLoot chests
    Version 0.2 (3/19/2011)
    • Fixed unknown command spamming chat
    • Fixed no Economy message spamming
    • added /loot info and /loot name (phatloots.info phateloots.name)
    Version 0.1 (3/18/2011)
    • Initial Release
     
  2. Offline

    Monkey_nuts

    can anyone help with this problem?
     
  3. Offline

    staniboy

    works on 1060?
     
  4. Offline

    Monkey_nuts

    Is there a way so that there can only be a certain amount of items that exist inside the chest at one time for exmple when the time for the chest to reset comes if there is already an item in the chest which it is set to add, then it cant add another one.

    For example you want 3 arrows and 1 bow to exist in that chest at any one time and when it comes to the reset time if all preset items exist then it doesn't add another set of the preset items.
     
  5. Offline

    PureSmurfy

    Can somebody help me? I just got this plug in for my server and it doesn't seem to work at all, I've been following every command correctly and everything; even named my chest 'Test' for good measure, still won't work. Is Permissions required? Are economy plugins required? I know there are no requirements on the post but I'm just making sure.

    thanks in advamce.
     
  6. Offline

    Viper766

    Does this need to be updated to work on 1.8?
    (sorry for noob questions im new to the sever host stuff lol :D)
     
  7. Offline

    gameswereus

    Please :)P) update this, as it's amazing.
     
  8. Offline

    Codisimus

  9. Offline

    bobeeb

    thnx for the dev version, working fine also with iconomy6
     
  10. Offline

    threepoint14159

    I'm sorry if this has already been made clear, but is this for build 1185?

    My server runs that build, and the only proof of its existence is the absence of the "Unknown command" message. Other than that, the dev build does not seem to be functional at all.
     
  11. Offline

    Codisimus

    yes it works with 1185. at least it should...
     
  12. Offline

    asm0deus

    It works.. but every person who opens the chest spawn a new set of items.
     
  13. Offline

    Codisimus

    that is what is suppose to happen...
     
  14. Offline

    asm0deus

    sorry, it adds them the items are not unique. When I used this about 6 months ago, each person got unique items. now, if three people open the chest, it spawns 3 sets of armor, items, etc instead of 1 for each (that only they can see).
     
  15. Offline

    Codisimus

    There is no way for me to make it so each person can only see their set of items. That is why I added the autoloot option so the items can go straight to their inventory
     
  16. Offline

    Dec64

    possible to add it so, when a player tries to open a chest, that they are not able to open yet, due to the timer function, the plugin will say like "Still xx mins before you can use chest again" ?
     
  17. Offline

    ItsQ

    Great for my Game world,
    Please update to new RB.
     
  18. Offline

    Sydael

    It doesn't work with latest bukkit, right?
    Time option doesn't work. People can take the loot from chest every time they click it.
    This is what i get after every usage of the lootchest:
    Code:
    2011-10-07 11:04:11 [SEVERE] Could not pass event PLAYER_INTERACT to PhatLoots
    java.lang.NullPointerException
        at PhatLoots.PhatLoots.lootCollective(PhatLoots.java:227)
        at PhatLoots.PhatLoots.getLoot(PhatLoots.java:72)
        at PhatLoots.PhatLootsPlayerListener.onPlayerInteract(PhatLootsPlayerListener.java:295)
        at org.bukkit.plugin.java.JavaPluginLoader$11.execute(JavaPluginLoader.java:314)
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58)
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:338)
        at org.bukkit.craftbukkit.event.CraftEventFactory.callPlayerInteractEvent(CraftEventFactory.java:168)
        at net.minecraft.server.ItemInWorldManager.interact(ItemInWorldManager.java:259)
        at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:592)
        at net.minecraft.server.Packet15Place.a(SourceFile:57)
        at net.minecraft.server.NetworkManager.b(NetworkManager.java:226)
        at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:92)
        at net.minecraft.server.NetworkListenThread.a(SourceFile:108)
        at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:464)
        at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:374)
        at net.minecraft.server.ThreadServerApplication.run(SourceFile:417)
    Also after stopping the server and putting it back up, all loots are gone.
    When i start the server, i notice this:
    Code:
    2011-10-07 11:11:10 [INFO] [PhatLoots] Load failed, saving turned off to prevent loss of data
    2011-10-07 11:11:10 [SEVERE] java.lang.NullPointerException
    2011-10-07 11:11:10 [SEVERE]     at java.util.Hashtable.put(Unknown Source)
    2011-10-07 11:11:10 [SEVERE]     at java.util.Properties.setProperty(Unknown Source)
    2011-10-07 11:11:10 [SEVERE]     at PhatLoots.SaveSystem.loadFromFile(SaveSystem.java:49)
    2011-10-07 11:11:10 [SEVERE]     at PhatLoots.PhatLootsMain.onEnable(PhatLootsMain.java:51)
    2011-10-07 11:11:10 [SEVERE]     at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:126)
    2011-10-07 11:11:10 [SEVERE]     at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:920)
    2011-10-07 11:11:10 [SEVERE]     at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:278)
    2011-10-07 11:11:10 [SEVERE]     at org.bukkit.craftbukkit.CraftServer.loadPlugin(CraftServer.java:173)
    2011-10-07 11:11:10 [SEVERE]     at org.bukkit.craftbukkit.CraftServer.enablePlugins(CraftServer.java:156)
    2011-10-07 11:11:10 [SEVERE]     at net.minecraft.server.MinecraftServer.e(MinecraftServer.java:297)
    2011-10-07 11:11:10 [SEVERE]     at net.minecraft.server.MinecraftServer.a(MinecraftServer.java:284)
    2011-10-07 11:11:10 [SEVERE]     at net.minecraft.server.MinecraftServer.init(MinecraftServer.java:152)
    2011-10-07 11:11:10 [SEVERE]     at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:348)
    2011-10-07 11:11:10 [SEVERE]     at net.minecraft.server.ThreadServerApplication.run(SourceFile:417)
    2011-10-07 11:11:10 [INFO] [PhatLoots] Load failed, saving turned off to prevent loss of data
    2011-10-07 11:11:10 [SEVERE] java.lang.NumberFormatException: null
    2011-10-07 11:11:10 [SEVERE]     at java.lang.Integer.parseInt(Unknown Source)
    2011-10-07 11:11:10 [SEVERE]     at java.lang.Integer.parseInt(Unknown Source)
    2011-10-07 11:11:10 [SEVERE]     at PhatLoots.SaveSystem.loadFromFile(SaveSystem.java:79)
    2011-10-07 11:11:10 [SEVERE]     at PhatLoots.PhatLootsMain.onEnable(PhatLootsMain.java:51)
    2011-10-07 11:11:10 [SEVERE]     at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:126)
    2011-10-07 11:11:10 [SEVERE]     at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:920)
    2011-10-07 11:11:10 [SEVERE]     at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:278)
    2011-10-07 11:11:10 [SEVERE]     at org.bukkit.craftbukkit.CraftServer.loadPlugin(CraftServer.java:173)
    2011-10-07 11:11:10 [SEVERE]     at org.bukkit.craftbukkit.CraftServer.enablePlugins(CraftServer.java:156)
    2011-10-07 11:11:10 [SEVERE]     at net.minecraft.server.MinecraftServer.e(MinecraftServer.java:297)
    2011-10-07 11:11:10 [SEVERE]     at net.minecraft.server.MinecraftServer.a(MinecraftServer.java:284)
    2011-10-07 11:11:10 [SEVERE]     at net.minecraft.server.MinecraftServer.init(MinecraftServer.java:152)
    2011-10-07 11:11:10 [SEVERE]     at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:348)
    2011-10-07 11:11:10 [SEVERE]     at net.minecraft.server.ThreadServerApplication.run(SourceFile:417)
    2011-10-07 11:11:10 [INFO] PhatLoots 0.9.1 is enabled!
    2011-10-07 11:11:10 [INFO] [PhatLoots] Successfully linked with iConomy 6!
    2011-10-07 11:11:10 [INFO] [PhatLoots] Successfully linked with LWC!
    I'm running on latest recommended build.
     
  19. Offline

    ItsQ

     
  20. Offline

    AzureFlameCloud

    this plugins is one of the best IMO but is this compatible with permissions ex?
     
  21. Offline

    Codisimus

    will be once I get a stable build which I think I just about have

    Here is a stable build
    http://dl.dropbox.com/u/23866327/Plugins/Test Jars/PhatLoots.jar
    Too tired to upload it tonight but it works with CB 1240 and includes new features like dispenser support and an option to display time remaining.


    The updated Permission nodes (PermissionsEx) can be found here
    http://dl.dropbox.com/u/23866327/Plugins/Test Jars/Permissions.txt


    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 12, 2016
  22. Offline

    Brvtvs

  23. Offline

    Codex Arcanum

    Is this compatible with iConomy 6.0.7? I just installed iConomy 6 and am now getting this error:
    Show Spoiler

    12:46:41 [SEVERE] Could not pass event PLUGIN_ENABLE to Heroes
    java.lang.NoClassDefFoundError: com/nijiko/coelho/iConomy/iConomy
    at com.nijikokun.register.payment.methods.iCo4.isCompatible(iCo4.java:54)
    at com.nijikokun.register.payment.Methods.createMethod(Methods.java:55)
    at com.nijikokun.register.payment.Methods.setMethod(Methods.java:94)
    at com.herocraftonline.dev.heroes.HPluginListener.onPluginEnable(HPluginListener.java:68)
    at org.bukkit.plugin.java.JavaPluginLoader$46.execute(JavaPluginLoader.java:562)
    at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58)
    at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:338)
    at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:927)
    at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:278)
    at org.bukkit.craftbukkit.CraftServer.loadPlugin(CraftServer.java:173)
    at org.bukkit.craftbukkit.CraftServer.enablePlugins(CraftServer.java:156)
    at net.minecraft.server.MinecraftServer.e(MinecraftServer.java:297)
    at net.minecraft.server.MinecraftServer.a(MinecraftServer.java:284)
    at net.minecraft.server.MinecraftServer.init(MinecraftServer.java:152)
    at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:348)
    at net.minecraft.server.ThreadServerApplication.run(SourceFile:417)

    Thanks!
     
  24. Offline

    Codisimus

    @Codex Arcanum
    it should be... For some reason it looks like it is trying to link to iConomy 4. What is economy set to in the config and what does it say it's linking to on startup?
     
  25. Offline

    Codex Arcanum

    Here is the phatloots section of the server startup log:
    Show Spoiler

    2011-10-08 12:58:18 [INFO] PhatLoots 0.9.1 is enabled!
    2011-10-08 12:58:18 [INFO] [PhatLoots] Successfully linked with Permissions!
    2011-10-08 12:58:18 [SEVERE] Could not pass event PLUGIN_ENABLE to PhatLoots
    java.lang.NoClassDefFoundError: com/nijiko/coelho/iConomy/iConomy
    at com.nijikokun.register.payment.methods.iCo4.isCompatible(iCo4.java:54)
    at com.nijikokun.register.payment.Methods.createMethod(Methods.java:55)
    at com.nijikokun.register.payment.Methods.setMethod(Methods.java:94)
    at PhatLoots.PluginListener.onPluginEnable(PluginListener.java:33)
    at org.bukkit.plugin.java.JavaPluginLoader$46.execute(JavaPluginLoader.java:562)
    at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58)
    at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:338)
    at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:927)
    at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:278)
    at org.bukkit.craftbukkit.CraftServer.loadPlugin(CraftServer.java:173)
    at org.bukkit.craftbukkit.CraftServer.enablePlugins(CraftServer.java:156)
    at net.minecraft.server.MinecraftServer.e(MinecraftServer.java:297)
    at net.minecraft.server.MinecraftServer.a(MinecraftServer.java:284)
    at net.minecraft.server.MinecraftServer.init(MinecraftServer.java:152)
    at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:348)
    at net.minecraft.server.ThreadServerApplication.run(SourceFile:417)
    Caused by: java.lang.ClassNotFoundException: com.nijiko.coelho.iConomy.iConomy
    at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
    at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:36)
    at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:24)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
    ... 16 more

    here is the configuration file:
    Show Spoiler

    #Config file for PhatLoots
    #Plugin made by Codisimus


    #Supported Economy plugins:
    #BOSEconomy, iConomy (4 or 5), Essentials, None

    Economy=iConomy


    #If set to true, PhatLoots will overlook Permissions
    #Only OPs will be able to make PhatLoots
    #Everyone will be able to loot items

    UseOP=false


    #If set to true items will go straight to player's inventory
    #Once inventory is full items will show up in the chest
    #Type \! instead of ! in order to use an exclamation point (ex. hi\!)
    #Use & to specify colors for messages (ex. &3hi&a.)

    AutoLoot=false
    AutoLootMessage=<item> was automatically added to your inventory.


    #Can be set to "user" or "global"
    #user = when a player loots a chest they must wait the specified time to loot again
    #global = when looted by one person, everyone must wait to loot it again (first person there gets the loot)

    DefaultResetType=user


    #The number of items that will be received from the collective loots

    DefaultNumberOfCollectiveLootItemsRecieved=1


    #Amount of time before the chest will reset "Days'Hours'Minutes'Seconds"
    #Change to "never" in order for it to never reset

    DefaultResetTime=1'0'0'0


    #If set to "true", when a PhatLoots chest is created it will automatically be made public with LWC

    AutoLockPhatLootChestsWithLWC=false

    Thanks!
     
  26. Offline

    AzureFlameCloud

    that was fast, thanks codisimus
    have a diamond!
     
  27. Offline

    Bekz

    please update for superperms // bukkitpermissions
     
  28. Offline

    Codisimus

  29. Offline

    gameswereus

    @Codisimus thanks so much!
     
  30. Offline

    staniboy

    @Codisimus oh sweet!
    Does it work with 1337? Anyone?
     
  31. Offline

    Codisimus

    it should, but I'm testing a newer version as we speak.
     
  32. Offline

    staniboy

    Oh man....with all those releases...I wonder if it's work on latest dev...im not sure if latest dev is working itself ;D
     

Share This Page