Surprise Bags
Description
This plugin adds various treasures and surprise bags to your world. These special items will be dropped by naturally-spawned monsters such as Zombies and Spiders. When players obtain the surprise bags, they can open them by clicking the right mouse button while holding them. They will then get a random item and the bag will disappear.
The list of surprise bags is set in the configuration files of the plugin, as well as the list of items that the player can receive when opening each bag. The plugin comes with a predefined set of bags:
- Treasure
- Trick-or-treat Box (perfect for Halloween)
- Surprise Bag
- Unknown Book
- Wintersday Gift (perfect for Christmas)
Each such item has a different drop-rate. Please see the configuration files for more information.
For example, players who open an Unknown Book might get a sharpness I enchanted book or a different enchanted book. Trick-or-treat boxes might get the player a raw fish, a pumpkin pie or, rarely, a diamond helmet.
Commands
There is one main command and several sub-commands:
- /surprisebags version - Get the plugin's version.
- /surprisebags spawn <bag> [count] [player] - Give you or a player a bag by name.
- /surprisebags list - List of existing bags.
- /surprisebags edit <bag> - Edit the bag's contents.
- /surprisebags save <bag> - Save the bag's contents to the configuration file.
- /surprisebags addbag <bag-id> [name] [drop-chance] - Add a new bag
- /surprisebags removebag <bag-id> - remove a custom bag
- /surprisebags reload - Reload the configuration files.
Permissions
There are three permission settings:
- surprisebags.command - Allows you to use the SurpriseBags admin command (defaults to admins only).
- surprisebags.openbag - Allows you to open bags (defaults to everyone).
- surprisebags.edit - Allows you to edit or save the bags contents (defaults to admins only).
Configuration
You may add/remove surprise bags by using the in-game commands. You can change different settings by editing config.yml, which is in the plugin's folder after installation. Each bag has its own YAML file, where you can list the items that players will receive when opening the bag. The players will always receive exactly one item, so adding many items of the same type will increase the chance of receiving them, whereas items which appear only once will be rare. You may open the configuration files of any of the predefined bags (e.g. Trick-or-treat box) to see how these lists work.
You may change the general drop-rate of bags, as well as the specific drop-rate of each bag.
If you have WorldGuard installed, you may limit the drops to one region. The region ID is set on config.yml.
If you want a bag to drop from a specific list of mobs, you can add the "limit-mob" setting to the bag's yaml file. For example:
# # Limit Mobs # # Limit the drop of this bag to the listed mobs only. # limit-mob: - creeper - zombie
Note that this should be in the bag's file, not in config.yml (in other words, it is defined per bag).
-
View User Profile
-
Send Message
Posted Aug 30, 2014Thanks
-
View User Profile
-
Send Message
Posted Jul 14, 2014@ejgj16
Thanks for reporting.
-
View User Profile
-
Send Message
Posted Jul 14, 2014sorry about my bad english,
i found a little bug, if you rename a item in an anvil, this loses the function, example if you have a enchanting table called: mysurprisetable, and rename it you can have a free enchanting table
-
View User Profile
-
Send Message
Posted Jun 20, 2014@eyalzh
He means: If you place 16 obsidian in 1 space of the chest GUI of the bag edit you will get only 1 obsidian if you open the bag
-
View User Profile
-
Send Message
Posted May 9, 2014@eyalzh Fixed!.
Oh, forgive that, my fault, and thanks for the quick responding.
-
View User Profile
-
Send Message
Posted May 8, 2014@Alararar
This is usually the error you see when there's an error one of the config files.
-
View User Profile
-
Send Message
Posted May 7, 2014With Spigot 1.7.9 i get this error when startup the server, but the plugin work normally.
-
View User Profile
-
Send Message
Posted Apr 29, 2014Seems like this doesn't work with Mob Arena...
-
View User Profile
-
Send Message
Posted Apr 26, 2014@Lobomite
Yes, you will always get one item. Having lots of the same item (e.g. a stack of obsidian) will increase the chance of getting one.
-
View User Profile
-
Send Message
Posted Apr 26, 2014Hey, am i doing something wrong or why i cant get multiple items from surprise bags? E.g. 16 obsidian -> you'll only get one
-
View User Profile
-
Send Message
Posted Apr 25, 2014@Clairefox
Fixed in 1.8.9
-
View User Profile
-
Send Message
Posted Apr 22, 2014@eyalzh It would be cool if you can make it so a item can give a command for exapmle you can add like paper named 5mill and it will excute the command /eco give {name} 5000000 to get the 5 mill
-
View User Profile
-
Send Message
Posted Apr 21, 2014@eyalzh
Any mob system that uses dark areas to spawn mobs while lighting up all the area around it so they only spawn in that one dark area. Like this one: https://www.youtube.com/watch?v=3S5x3qxl8s8
-
View User Profile
-
Send Message
Posted Apr 20, 2014@Clairefox
Can you describe one of those passive mob systems?
-
View User Profile
-
Send Message
Posted Apr 20, 2014Can it be made so that the player has to actually kill the mob to receive the bag? I'm having a lot of players using their passive mob systems to get large numbers of the bags w/o any work D:
-
View User Profile
-
Send Message
Posted Apr 19, 2014@broluigi
I'll try to add permission per box to the next version.
You can add other boxes to existing boxes. Just use the in-game edit command.
-
View User Profile
-
Send Message
Posted Apr 19, 2014can you make it so i can give permission specific loot boxes? i made a bunch of donator boxes but i am trying to make a box just for non donators but permissions arent versatile enough
can you add a chance for certain boxes to give other boxes?
-
View User Profile
-
Send Message
Posted Mar 23, 2014@Lobomite
Not at the moment. That's the bag ID.
-
View User Profile
-
Send Message
Posted Mar 22, 2014@eyalzh
Yeah it works now, i didnt even know there was a ingame command, how convinient :) One problem though, is it possible to get rid off the purple "surprisebag" lore from the bags?
-
View User Profile
-
Send Message
Posted Mar 21, 2014@Lobomite
I suggest you use the in-game edit and save commands, they will make it much easier to edit and create new bags.
e.g.
/sbag edit wintersday-gift