[MECH] OtherDrops 2.8- Ultimate block/mob/player drop editing [1.5.2]

Discussion in 'Archived: Plugin Releases' started by Zarius, Jun 12, 2011.

  1. Offline

    Zarius

    [​IMG]


    Want to fix glass/stairs/boat drops? Want to gather ice/glowstone/grass in a balanced manner? Want to smelt ore with golden tools? Want to cause chaos with undead that rise again? Now you can, simply by enabling the included example files or delve into the more advanced customisation and make drops work the way you want.

    OtherBlocks aims to give you ultimate control over what item that blocks/entities drop when destroyed, depending on how they were destroyed. Compatible with WorldGuard. Lightweight! Only scans what it needs to and ignores the rest.
    Download: BukkitDev (download link on there) | Source Code

    Included Modules
    * Fix undroppables: fix drops for stairs, glass (don't use your hands - ouch), boats & bookshelves (1.8 stairs included)
    * Gold tools (basic): gold tools have a chance of dropping the complete block for grass, ice & glowstone.
    * Gold tools (smelt): gold tools have a chance of mining an ingot directly from ores.
    * Ore Extraction: using the usual tools, ingots are ripped out of ores, leaving the stone behind.
    * Leaf overhaul: adds leaf drops (apples, cocoa, leaves, sticks & a very small chance of golden apple).
    * Undead Chaos: beware the night! Zombies & skeletons rise again and even players rise back from the dead (player deaths spawn more zombies/skeletons).
    * and more...

    Custom Configuration Examples
    Code:
        # Simple glass drop fix
        GLASS:
          - drop: GLASS
     
        # Players drop Zombies on death, 50% of the time
        PLAYER:
          - drop: CREATURE_ZOMBIE
            chance: 50%
     
        # Spiders killed with any sword at night have a 10% chance to drop web,
        # otherwise they drop whatever they normally would
        CREATURE_SPIDER:
          - tool: ANY_SWORD
            time: NIGHT
            drop: WEB
            chance: 10%
     
        # Trees drop apples (or cocoa from birch trees)
        SPECIAL_LEAFDECAY@GENERIC:
          - drop: APPLE
            chance: 5%
        SPECIAL_LEAFDECAY@BIRCH:
          - drop: DYE@BROWN
            chance: 5%
    
    If you are getting errors with the word "snakeyaml" in it, your config file isn't properly formatted.
    Test it on this website (or this one).

    See the dev.bukkit page for full details on how to set up OtherDrops, a complete parameters list and further examples.


    Changelog

    Newest changelog details here.


    Main author: @Zarius
    Contributors: @Celtic Minstrel, raws
    Original author: @cyklo
     
  2. Offline

    Celtic Minstrel

    &(0-9a-f)
     
  3. Offline

    RugRats

    Thats what I was looking for :D
     
  4. Offline

    EMOberger

    Could i make it drop to things? ex:

    CREATURE_SLIME:
    - tool: ALL
    drop: DEFAULT
    drop: MONEY
    quantity: 0.00-0.01
    message: That Slime droped %q ***!

    ???
     
  5. Offline

    RugRats

    Code:
        CREATURE_SLIME:
            - tool: ANY
              drop: DEFAULT
              quantity: 0.00-0.01
              message: Whatever
            - tool: ANY
              drop: MONEY
              quantity: 0-500
              message: This is your second drop :)
     
  6. Offline

    EMOberger

    so i do have to make another section :[ oh well thank you.
    one more thing tho do i have to set a quantity if the drop is set to default?
     
  7. Offline

    RugRats

    Nope you don't have to if it's default
     
    EMOberger likes this.
  8. Offline

    EMOberger

    .........
    ok i have tryed a couple of different ways to get a monster to drop default and money but it is not working.
    any help?
     
  9. Offline

    Zarius

    @EMOberger
    Try:
    Code:
        CREATURE_SLIME:
            - drop: DEFAULT  # just making sure it still drops the default drop
    
            - tool: ANY
              drop: MONEY
              quantity: 0.00-0.01  # this means 50% of the time you get 1 cent, and 50% of time nothing (along with a message stating "That Slime dropped $0! - not sure if this is what you wanted.  Perhaps try chance: 50% with quantity 0.01, or a different range, say 0.01-0.05?
              message:  That Slime dropped $%q ***!
    
    # you can keep adding as many drops as you like, adding any parameters you want
            - tool: ANY
              drop: DIAMOND
              quantity: 1
              chance: 5%
              message:  That Slime dropped a diamond too!
    
     
  10. Offline

    EMOberger

    OK i have it set like this and it is still only dropping money...
    Code:
    # Set this to "low" to reduce number of boot messages or to high, highest, extreme for more debugging info
    verbosity: normal
    
    # Try adjusting this if you have compatibility problems with other plugins.
    # Default: "lowest". Can also use "low", "normal", "high", "highest".
    priority: lowest
    
    # experimental water damage (DANGEROUS - disabled above "enableblockto")
    # supposed to allow you to change the drop if a torch is destroyed by water (DAMAGE_WATER, doesn't work yet)
    # this setting CAN crash your server if set to true and configured incorrectly
    enableblockto: false
    
    ##########
    # PERMISSIONS: set to true to use the permissions system (ensure users have the "otherblocks.active" permission)
    ##########
    usepermissions: false
    ##########
    
    
    ##########
    # Include files
    ##
    # The plugin will scan through and load these files (if set to 'yes') after loading the main config below.
    # Extension ".yml" is added automatically before searching for the file
    #
    # Note: drops from included files will are inclusive and will all be added to the drop list.
    # Note when updating OtherBlocks: these files may be updated from time to time - rename them if you don't want to overwrite them.
    #
    include-files: 
    #    ob-fix_undroppables: no      # fix glass, bookshelf, boat and stairs drops
    #    ob-fix_undroppables_opt: no  # allow gold-pickaxe chance to get ice & glowstone, gold-hoe chance to get grass
    
    #    ob-leaf_overhaul: no         # overhaul leaf drops (apples, cocoa beans, leaves, sticks & a very small chance of golden apple)
    
        ob-playerdeath_zombie: yes    # players drop zombies on death (that's it - see undead_chaos for more fun :D)
    #    ob-undead_chaos: no             # the undead shall rise again! Includes players dropping zombies/skeletons
    #    ob-random_examples: no      # For crazy testing only :) Read through examples before activating.
    
    # Other users overhauls
    #    catballs-overhaul: no        # great example/playable config from Catballs (disable "ob" configs before using this one, otherwise you might have too many drops)
    
    
    ##########    
    otherblocks:
    ##########
    # This is a sample configuration file for OtherBlocks
    # Configuration blocks are set out as followed:
    #
    # NAME_OF_ORIGINAL_BLOCK:
    #     - tool: NAME_OF_TOOL (or ALL for all tools. Accepts lists like [toola, toolb])
    #       world: WHICH_WORLD (optional. Accepts lists like [worlda, worldb])
    #       drop: NAME_OF_NEW_DROP (can be any block/item or MONEY [see money section])
    #
    ### Optional parameters ###
    #
    #       color: COLOUR_OF_NEW_BLOCK (default WHITE, only applies to WOOL/DYE/INK_SACK drops)
    #       quantity: AMOUNT_OF_NEW_DROP (optional, default 1)
    #       damage: TOOL_DAMAGE (optional, default 1)
    #       chance: DROP_PROBABILITY_PERCENTAGE (optional, default 100)
    #       permissiongroup: list of groups this applies to (eg. [Citizen,Moderator]) not case sensitive
    #       permissiongroupexcept: apply this drop to all groups _except_ this list
    #       message: Message to be shown to the player on a drop (can be a list - one gets selected at random)
    #        time: DAY or NIGHT (optional, drop only occurs during day or night)
    #       weather: RAIN, THUNDER, CLEAR (accepts lists eg. [RAIN, THUNDER])
    #       event: LIGHTNING, TREE, EXPLOSION (accompany the drop with an event)
    #                     also TREE@BIG_TREE, TREE@BIRCH, TREE@REDWOOD, TREE@TALL_REDWOOD
    #          !!!BEWARE!!! - there is no check to see if chests are destroyed with trees
    #
    # For lists of appropriate values to use, see:
    #  - Block and tools: http://cliqr.org/V
    #  - Colors:          http://cliqr.org/Y
    #
    # If you want to add a different drop based on a
    # different tool but for the same original block,
    # simply repeat the indented block again, but make
    # sure you start with "- tool", e.g.
    #
    ######
    # Simple Example (see other included config files for more examples)
    ######
    #
    # GRASS:
    #     - tool: GOLD_SPADE          # drop grass if the player uses a golden spade
    #       drop: GRASS
    #
    #     - tool: ALL                 # for all tools _except_ the gold spade, drop dirt
    #       toolexcept: GOLD_SPADE
    #       drop: DIRT
    #
    # NOTE: A "tool: ALL" statement sets the drop for any
    # tools not yet specified. Therefore, it should
    # always be the last item in a list.
    #
    #### Money
    #
    #   For money drops use MONEY in the drop parameter and the amount in the "quantity" parameter.
    #
    #   Amounts can be decimal eg. "quantity: 0.5-1.67".
    #   For negatives use a ~ character as the separator eg. "quantity: -5.5~-2.5"
    #
    ##########
    # Economy examples
    #
    ## Killing skeletons gives between 10.25 and 50.45 currency
    #        CREATURE_SKELETON:
    #            - tool: ANY_SWORD
    #              drop: MONEY
    #              quantity: 10.25-50.45
    #
    ## Killing sheep subtracts between -10 and -2 currency 
    #        CREATURE_SHEEP:
    #            - tool: ANY_SWORD
    #              drop: MONEY
    #              quantity: -10~-2
    #              message: You killed a poor sheep :(  Lose %q currency.
    ##########
    
    #
    # Your changes here, or create a new .yml file and include it above in the "include-files" section
    # Explore the included config files for many more examples
    #
    # If make a interesting or crazy config let me know on the forum and I might include it in the next release
    #
    #
            CREATURE_CREEPER:
                - drop: DEFAULT
    
                - tool: ALL
                  drop: MONEY
                  quantity: 0.00-0.10
                  message: That Creeper droped %q Ryo!
    
    
            CREATURE_GHAST:
                - drop: DEFAULT
    
                - tool: ALL
                  drop: MONEY
                  quantity: 0.05-0.15
                  message: That Ghast droped %q Ryo!
    
    
            CREATURE_GIANT:
                - drop: DEFAULT
    
                - tool: ALL
                  drop: MONEY
                  quantity: 0.00-1.00
                  message: That Giant droped %q Ryo!
    
    
            CREATURE_PIG_ZOMBIE:
                - drop: DEFAULT
    
                - tool: ALL
                  drop: MONEY
                  quantity: 0.00-0.10
                  message: That Pig Zombie droped %q Ryo!
    
    
            CREATURE_SKELETON:
                - drop: DEFAULT
    
                - tool: ALL
                  drop: MONEY
                  quantity: 0.00-0.05
                  message: That Skeleton droped %q Ryo!
    
    
            CREATURE_SPIDER:
                - drop: DEFAULT
    
                - tool: ALL
                  drop: MONEY
                  quantity: 0.00-0.07
                  message: That Spider droped %q Ryo!
    
    
            CREATURE_ZOMBIE:
                - drop: DEFAULT
    
                - tool: ALL
                  drop: MONEY
                  quantity: 0.00-0.05
                  message: That Zombie droped %q Ryo!
    
    
            CREATURE_SLIME:
                - drop: DEFAULT
    
                - tool: ALL
                  drop: MONEY
                  quantity: 0.00-0.01
                  message: That Slime droped %q Ryo!
     
  11. Offline

    Zarius

    @EMOberger

    Ok, looks like you're using an old version of OtherBlocks - which version is it? Please upgrade to 1.5 (trying the latest beta would be even better) and try again (otherwise I'm looking for a bug that might already be fixed).
     
  12. Offline

    EMOberger

    oh.. that's my mistake i could of sworn that i updated >.> sorry i have 37 plugins that i have to keep track of, gets hard to update.

    OK now i am on beta 1.6 with this config:
    Code:
    configversion: 2
    
    # Set this to "low" to reduce number of boot messages or to high, highest, extreme for more debugging info
    verbosity: normal
    
    # Try adjusting this if you have compatibility problems with other plugins.
    # Default: "lowest". Can also use "low", "normal", "high", "highest".
    priority: lowest
    
    # experimental water damage (DANGEROUS - disabled above "enableblockto")
    # supposed to allow you to change the drop if a torch is destroyed by water (DAMAGE_WATER, doesn't work yet)
    # this setting CAN crash your server if set to true and configured incorrectly
    enableblockto: false
    
    ##########
    # PERMISSIONS: set to true to use the permissions system (ensure users have the "otherblocks.active" permission)
    ##########
    usepermissions: false
    ##########
    
    ##########
    # Include files
    ##
    # The plugin will scan through and load these files (if set to 'yes') after loading the main config below.
    # Extension ".yml" is added automatically before searching for the file
    #
    # Note: drops from included files will are inclusive and will all be added to the drop list.
    # Note when updating OtherBlocks: these files may be updated from time to time - rename them if you don't want to overwrite them.
    #
    include-files: 
    ## OtherBlocks example files
    #    ob-fix_undroppables: no      # fix glass, bookshelf, boat and stairs drops
    #    ob-goldtools-basic: no       # allow gold-pickaxe chance to get ice & glowstone, gold-hoe chance to get grass
    #    ob-goldtools-smelt: no       # gold-pickaxe smelts ores to ingots, sand to glass, etc
    #    ob-leaf_overhaul: no         # overhaul leaf drops (apples, cocoa beans, leaves, sticks & a very small chance of golden apple)
        ob-playerdeath_zombie: yes    # players drop zombies on death (that's it - see undead_chaos for more fun :D)
    #    ob-undead_chaos: no          # the undead shall rise again! Includes players dropping zombies/skeletons
    #    ob-random_examples: no      # For crazy testing only :) Read through examples before activating.
    
    ## Other users overhauls
    #    overhaul-catballs: no        # great example/playable config from Catballs (disable "ob" configs before using this one, otherwise you might have too many drops)
     #   overhaul-zarius: no          # Zar's messy config (I run this with no other includes, at the moment)
        
    ## Add your files here (alternatively just add your custom drops to the bottom of this file)
        #my_custom_file1: yes
    
    ##########    
    otherblocks:
    ##########
    # This is a sample configuration file for OtherBlocks
    # Configuration blocks are set out as followed:
    #
    # NAME_OF_ORIGINAL_BLOCK:
    #     - tool: NAME_OF_TOOL (or ALL for all tools. Accepts lists like [toola, toolb])
    #       world: WHICH_WORLD (optional. Accepts lists like [worlda, worldb])
    #       drop: NAME_OF_NEW_DROP (can be any block/item or MONEY [see money section])
    #
    ### Optional parameters ###
    #
    #       color: COLOUR_OF_NEW_BLOCK (default WHITE, only applies to WOOL/DYE/INK_SACK drops)
    #       quantity: AMOUNT_OF_NEW_DROP (optional, default 1)
    #       damage: TOOL_DAMAGE (optional, default 1)
    #       chance: DROP_PROBABILITY_PERCENTAGE (optional, default 100)
    #       permissiongroup: list of groups this applies to (eg. [Citizen,Moderator]) not case sensitive
    #       permissiongroupexcept: apply this drop to all groups _except_ this list
    #       message: Message to be shown to the player on a drop (can be a list - one gets selected at random)
    #        time: DAY or NIGHT (optional, drop only occurs during day or night)
    #       weather: RAIN, THUNDER, CLEAR (accepts lists eg. [RAIN, THUNDER])
    #       event: LIGHTNING, TREE, EXPLOSION (accompany the drop with an event)
    #                     also TREE@BIG_TREE, TREE@BIRCH, TREE@REDWOOD, TREE@TALL_REDWOOD
    #          !!!BEWARE!!! - there is no check to see if chests are destroyed with trees
    #
    # For lists of appropriate values to use, see:
    #  - Block and tools: http://cliqr.org/V
    #  - Colors:          http://cliqr.org/Y
    #
    # If you want to add a different drop based on a
    # different tool but for the same original block,
    # simply repeat the indented block again, but make
    # sure you start with "- tool", e.g.
    #
    ######
    # Simple Example (see other included config files for more examples)
    ######
    #
    # GRASS:
    #     - tool: GOLD_SPADE          # drop grass if the player uses a golden spade
    #       drop: GRASS
    #
    #     - tool: ALL                 # for all tools _except_ the gold spade, drop dirt
    #       toolexcept: GOLD_SPADE
    #       drop: DIRT
    #
    # NOTE: A "tool: ALL" statement sets the drop for any
    # tools not yet specified. Therefore, it should
    # always be the last item in a list.
    #
    #### Money
    #
    #   For money drops use MONEY in the drop parameter and the amount in the "quantity" parameter.
    #
    #   Amounts can be decimal eg. "quantity: 0.5-1.67".
    #   For negatives use a ~ character as the separator eg. "quantity: -5.5~-2.5"
    #
    ##########
    # Economy examples
    #
    ## Killing skeletons gives between 10.25 and 50.45 currency
    #        CREATURE_SKELETON:
    #            - tool: ANY_SWORD
    #              drop: MONEY
    #              quantity: 10.25-50.45
    #
    ## Killing sheep subtracts between -10 and -2 currency 
    #        CREATURE_SHEEP:
    #            - tool: ANY_SWORD
    #              drop: MONEY
    #              quantity: -10~-2
    #              message: You killed a poor sheep :(  Lose %q currency.
    ##########
    
    #
    # Your changes here, or create a new .yml file and include it above in the "include-files" section
    # Explore the included config files for many more examples
    #
    # If make a interesting or crazy config let me know on the forum and I might include it in the next release
    #
    #
            CREATURE_CREEPER:
                - drop: DEFAULT
    
                - tool: ALL
                  drop: MONEY
                  quantity: 0.00-0.10
                  message: That Creeper droped %q Ryo!
    
    
            CREATURE_GHAST:
                - drop: DEFAULT
    
                - tool: ALL
                  drop: MONEY
                  quantity: 0.05-0.15
                  message: That Ghast droped %q Ryo!
    
    
            CREATURE_GIANT:
                - drop: DEFAULT
    
                - tool: ALL
                  drop: MONEY
                  quantity: 0.00-1.00
                  message: That Giant droped %q Ryo!
    
    
            CREATURE_PIG_ZOMBIE:
                - drop: DEFAULT
    
                - tool: ALL
                  drop: MONEY
                  quantity: 0.00-0.10
                  message: That Pig Zombie droped %q Ryo!
    
    
            CREATURE_SKELETON:
                - drop: DEFAULT
    
                - tool: ALL
                  drop: MONEY
                  quantity: 0.00-0.05
                  message: That Skeleton droped %q Ryo!
    
    
            CREATURE_SPIDER:
                - drop: DEFAULT
    
                - tool: ALL
                  drop: MONEY
                  quantity: 0.00-0.07
                  message: That Spider droped %q Ryo!
    
    
            CREATURE_ZOMBIE:
                - drop: DEFAULT
    
                - tool: ALL
                  drop: MONEY
                  quantity: 0.00-0.05
                  message: That Zombie droped %q Ryo!
    
    
            CREATURE_SLIME:
                - drop: DEFAULT
    
                - tool: ALL
                  drop: MONEY
                  quantity: 0.00-0.01
                  message: That Slime droped %q Ryo!
    
    but now only default drops...and i get this error:
    Code:
    Could not pass event ENTITY_DEATH to OtherBlocks
    java.lang.NullPointerException
        at com.gmail.zariust.bukkit.otherblocks.OtherBlocksDrops.checkDrops(OtherBlocksDrops.java:343)
        at com.gmail.zariust.bukkit.otherblocks.OtherBlocksEntityListener.onEntityDeath(OtherBlocksEntityListener.java:113)
        at org.bukkit.plugin.java.JavaPluginLoader$59.execute(JavaPluginLoader.java:656)
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58)
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:332)
        at net.minecraft.server.EntitySkeleton.q(EntitySkeleton.java:101)
        at net.minecraft.server.EntityLiving.die(EntityLiving.java:447)
        at net.minecraft.server.EntityLiving.damageEntity(EntityLiving.java:391)
        at net.minecraft.server.EntityMonster.damageEntity(EntityMonster.java:43)
        at net.minecraft.server.EntityHuman.d(EntityHuman.java:561)
        at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:858)
        at net.minecraft.server.Packet7UseEntity.a(SourceFile:33)
        at net.minecraft.server.NetworkManager.b(NetworkManager.java:226)
        at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:85)
        at net.minecraft.server.NetworkListenThread.a(SourceFile:105)
        at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:451)
        at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:361)
        at net.minecraft.server.ThreadServerApplication.run(SourceFile:422)
    2011-07-26 00:29:39 [SEVERE] Could not pass event ENTITY_DEATH to OtherBlocks
    java.lang.NullPointerException
        at com.gmail.zariust.bukkit.otherblocks.OtherBlocksDrops.checkDrops(OtherBlocksDrops.java:343)
        at com.gmail.zariust.bukkit.otherblocks.OtherBlocksEntityListener.onEntityDeath(OtherBlocksEntityListener.java:113)
        at org.bukkit.plugin.java.JavaPluginLoader$59.execute(JavaPluginLoader.java:656)
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58)
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:332)
        at net.minecraft.server.EntityLiving.q(EntityLiving.java:467)
        at net.minecraft.server.EntityLiving.die(EntityLiving.java:447)
        at net.minecraft.server.EntityLiving.damageEntity(EntityLiving.java:391)
        at net.minecraft.server.EntityMonster.damageEntity(EntityMonster.java:43)
        at net.minecraft.server.EntityHuman.d(EntityHuman.java:561)
        at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:858)
        at net.minecraft.server.Packet7UseEntity.a(SourceFile:33)
        at net.minecraft.server.NetworkManager.b(NetworkManager.java:226)
        at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:85)
        at net.minecraft.server.NetworkListenThread.a(SourceFile:105)
        at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:451)
        at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:361)
        at net.minecraft.server.ThreadServerApplication.run(SourceFile:422)
    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 16, 2016
  13. Offline

    Zarius

    I know how that is - I run with about 76 plugins :D

    Hmm... will look into this and send you a new version...

    @EMOberger

    Should be fixed in newest beta (1.7).

    @Everyone

    New beta version - needs a little testing then I'll release 1.7 full. Added event: lightning@player (strikes lightning where the player is currently standing) and lightning@playerlocation (strikes lightning where the player was standing when block/creature destroyed - good with a delay).

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

    EMOberger

    Thank you very much will test soon :]
    also i was wondering, anyway you could add somthing in the players tags allowing someone to exicute a command on player death?
    ex: when a player dies server exicutes command /jail %p -1 main you died
    were as "%p" is the players name.
    plugin that command is from:http://forums.bukkit.org/threads/admn-rpg-jail-v1-2-2-jail-bad-players-953.1912/
    just in case you needed or wanted to see xD
     
  15. Offline

    Zarius

    Hmm... that'd be tricky but could be interesting to have a "command:" parameter. Adding to todo list :)
     
  16. Offline

    EMOberger

    Thank you :] can't wait!
    and i am happy to say that your update worked, thanks again!
     
  17. Offline

    Zarius

    Could take a while - depends on how much free time I have :) Currently got 37 features on the todo list :D

    Actually - you're right! :) I didn't think of it but you can just delay the lightning instead, by using dropgroups - eg.

    Code:
            GRASS:
              - dropgroup: lightningglass
                chance: 3%
                drops:
                  - tool: ALL
                    drop: GLASS
                  - drop: NOTHING
                    event: LIGHTNING@PLAYERLOCATION
                    delay: 20-60
                  - drop: NOTHING
                    event: LIGHTNING@PLAYERLOCATION
                    delay: 40-80
                  - drop: NOTHING
                    event: LIGHTNING@PLAYERLOCATION
                    delay: 70-140
    
    This code also demonstrates the new lightning@playerlocation event in version 1.7beta2.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 16, 2016
  18. Getting these a lot:

    Code:
    16:12:45 [SEVERE] Could not pass event PAINTING_BREAK to OtherBlocks
    java.lang.NullPointerException
            at com.gmail.zariust.bukkit.otherblocks.OtherBlocksDrops.checkDrops(OtherBlocksDrops.java:166)
            at com.gmail.zariust.bukkit.otherblocks.OtherBlocksEntityListener.onPaintingBreak(OtherBlocksEntityListener.java:124)
            at org.bukkit.plugin.java.JavaPluginLoader$57.execute(JavaPluginLoader.java:641)
            at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58)
            at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:338)
            at net.minecraft.server.EntityPainting.damageEntity(EntityPainting.java:205)
            at net.minecraft.server.EntitySnowball.m_(EntitySnowball.java:173)
            at net.minecraft.server.World.entityJoinedWorld(World.java:1198)
            at net.minecraft.server.WorldServer.entityJoinedWorld(WorldServer.java:48)
            at net.minecraft.server.World.playerJoinedWorld(World.java:1180)
            at net.minecraft.server.World.cleanUp(World.java:1104)
            at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:447)
            at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:361)
            at net.minecraft.server.ThreadServerApplication.run(SourceFile:422)
    
     
  19. Offline

    Zarius

    You often get people throwing snowballs at paintings? :)

    Try the latest version (1.7) - I tested throwing snowballs at paintings and got no errors.

    @Everyone

    Latest version released:
    Version 1.7
    * added "delay" parameter (time specified in ticks)
    * added BigBrother API support
    * added WorldGuard "regions" condition to DropGroups

    * added messages to DropGroups
    * added events: LIGHTNING@PLAYER (strikes where the player currently is), LIGHTNING@PLAYERLOCATION (strikes where the player was at time block was broken, useful in combination with delay) and harmless variants.
     
  20. Offline

    RugRats

    He must have some fairly odd players... Lol
     
  21. We get everything, glad it wasn't a common event bugging instead ;)

    Thanks for fix!
     
  22. Offline

    TheMap

    Its a great plugin and I have used others in the past but since I just came back I was wondering if this plugin allows for specific groups to be flagged for bonus drops. Say Group A.... gets 20% more chance to X and Group B gets a 20% chance to drop Y?
     
  23. Offline

    RugRats

    Yep :D it sure does. I would look into dropgroups

    @Zarius Bug/Please fix
    i have made it so glass hurts you every so often and the damage bypasses essentials godmode so is there a way to fix this?

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

    Zarius

    Not yet, tricky to do as I have to query Essentials to see if godmode is switched on... Will add to todo list as possible feature.

    Yes - example:
    Code:
      GRASS:
        - drop: EGG
          chance: 20%
          permissiongroupexcept:  [groupa, groupb]
    
        - drop: EGG
          chance: 40%
          permissiongroup:groupa
    
        - drop: DIAMOND
          chance: 20%
          permissiongroup:groupb
    
    (not sure if you wanted groupb to drop Y in addition to X, but that's easy to do too)

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

    enelar

    Guys, thanks a lot for aliases, that destroy many hours of work.
    In this appeared free time, i generated new question xD
    What if i want create groups of drop?
    ex: (10%diamond+20%gold) EXCLUSIVE OR (100% golden apple)
     
  26. Offline

    Zarius

    Just add the exclusive option to the golden apple and set out to what ever name you want. Check out the sand drop in "overhaul-zarius" for another example (I think... otherwise will post an example when I get home.
     
  27. Offline

    enelar

    ex: (10%a+20%b) EXCLUSIVE OR (34%c+54%d) EXCLUSIVE OR (50%a+64%d)

    ^___^

    p.s
    Code:
    otherblocks:
    # aliases
            - &damageall
              tool: ALL
              drop: AIR
              damageattacker: 1
            - &defaultdrop
              tool: ALL
              drop: DEFAULT
              chance: 5
            - &specitem
              tool: ALL
              drop: DEFAULT
              chance: 100
              exclusive: 1
    
    #stones
        STONE:
            - <<: *damageall
            - <<: *defaultdrop
            - <<: *specitem
              tool: ANY_SPADE
    
    right?
     
  28. Offline

    Zarius

    Close - you need a tag on that alias block eg.
    Code:
    otherblocks:
        ALIASES:
            - ...etc
    
    Otherblocks will complain about not being able to read the matID for ALIASES but other than that it's ok.

    Noticed that exclusive doesn't stop the damageattacker option - I've fixed that and will post 1.71 soon.

    Code:
        GRASS:
            - dropgroup: blah
              exclusive: 1
              drops:
                  - drop: a
                    chance: 10%
                  - drop: b
                    chance: 20%
    
            - dropgroup: blah1
              exclusive: 2
              drops:
                  - drop: c
                    chance: 34%
                  - drop: d
                    chance: 54%
    
            - dropgroup: blah2
              exclusive: 3
              drops:
                  - drop: a
                    chance: 50%
                  - drop: d
                    chance: 64%
    
    Definately multiworld support :)

    Code:
        STONE: [{drop: APPLE, world: skyland}, {drop: EGG, world: [world, nether]}] 
    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 16, 2016
  29. Offline

    EMOberger

    xD i guess i didn't delete my question fast enough lmao I've been up for a wile and asked even tho i already knew that xDDD
    no matter, thanks :D

    so could i make a whole new config file for a world? ex: otherblocks-underworldconfig.yml
    underworld being the new world?
     
  30. Offline

    enelar

    Kkay, thanks.
     
  31. Offline

    Zarius

    Yup - you can set the default world in the defaults: section of the file so you don't need to keep typing it in. See the leaf overhaul file for an example.

    @enelar

    Saw your first post :) Yeah, you get a few error messages on normal verbosity - try low? You can also add the aliases above the otherblocks: section and they are completely ignored by the plugin but still work fine. Eg:

    Code:
    aliases:
              - &damageall
                tool: ALL
                drop: AIR
                damageattacker: 1
              - &defaultdrop
                tool: ALL
                drop: DEFAULT
                chance: 50
              - &specitem
                tool: ALL
                drop: DEFAULT
                chance: 100
                exclusive: 1
    
    otherblocks:
        STONE:
         ..... etc
    
    Oh, another thing to keep in mind - with your previous example of the spade breaking stone and dropping default: note that the default drop for a spade on stone is to drop nothing.

    I've reviewed some stuff on priorities and I think the next version of OtherBlocks will have default priority set to high. This way other plugins should clash less as OtherBlocks should be running after them.

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

Share This Page