[INACTIVE][MECH] OtherBlocks v0.7.4 - Customize drops in combo with everything else [617]

Discussion in 'Inactive/Unsupported Plugins' started by cyklo, Feb 11, 2011.

  1. Offline

    cyklo

    OtherBlocks - Customize what broken blocks and dead mobs drop!
    Version: 0.7.4
    Download: Jar File | Source Code
    Like this plugin? [​IMG]

    Main author: @cyklo
    Contributors: @Celtic Minstrel

    See the Wiki page for full details on how to set up OtherBlocks

    If you are getting errors with the word "snakeyaml" in it, your config file isn't properly formatted.
    Test it on this website.


    OtherBlocks is a plugin that lets you apply rules to what blocks drop when destroyed, depending on what tool you used. It is inspired by decino's goldenNether plugin.

    You can set rules in the configuration file to match any item with any block and give it a different drop item. For example, you could allow gathering of Glowstone Dust on the overworld by breaking Redstone ore with a golden pickaxe. Or you could allow ingots to be mined directly from their ores if you use Flint and Steel. Or you could invoke Isaiah Mustafa and decree "THE LEAVES ARE NOW DIAMONDS!"

    To install, simply decompress the contents to your plugins directory. Then, copy otherblocks/config.sample.yml to otherblocks/config.yml and edit away!

    Don't forget - to see how to edit the config file, check out out the Wiki!



    Changelog (open)

    Version 0.7
    • Added new drop types DEFAULT and NOTHING (0.7.4)
    • Fixed: creature drops don't work in specific worlds (0.7.4)
    • Added new mob types: CREATURE_GIANT, CREATURE_MONSTER, CREATURE_WOLF (0.7.3)
    • Will no longer throw problems with new types of mob when out of date (0.7.3)
    • Can specify creatures as the tool of death for mobs (0.7.2)
    • Can specify damage events as the tool of death for mobs (0.7.2)
    • Can specify data (colour) values for when you kill a sheep (0.7.2)
    • Fixed: doesn't work on CB 561+ (0.7.2)
    • Can specify data values for SPECIAL_LEAFDECAY events (0.7.2)
    • Large internal changes (0.7.2)
    • Fixed: number of spawned mobs did not obey config file (0.7.1)
    • Fixed: NullPointerException on mob item drop (0.7.1)
    • "color:" works for more than just wool and dyes, now works for wood, half-height blocks, crops etc. (0.7)
    • Synonyms, allowing you to specify groups such as "ANY_REDSTONE_ORE" and "ANY_PICKAXE" (0.7)
    • Can now specify data value of blocks you are dropping from, e.g. "CROPS@RIPE" (0.7)
    • Can now drop a number of items in a range (0.7) (by Celtic Minstrel)
    • Can now drop "CONTENTS" of containers, e.g. dispensers, furnaces (0.7) (by Celtic Minstrel)
    Version 0.6
    • Added SPECIAL_LEAFDECAY tag. See the wiki. (0.6.2)
    • Back-end changes to build process (0.6.1)
    • Multiworld support! Now you can customize drops on a per-world basis (0.6)
    Version 0.5

    • Now you can change what a mob drops when it is killed by a player! (0.5)
    Version 0.4

    • Fixed the map-break AIR bug (0.4.6)
    • Now specify multiple tools at the same time with syntax [TOOL_A, TOOL_B] (0.4.5)
    • Fixed incorrect colours of dropped dyes (0.4.4)
    • Added "ANY" as synonym for "ALL" (0.4.4)
    • Adjustable priority (0.4.3)
    • Can hide boot messages with "verbosity: low" (0.4.2)
    • Quantity and Damage bugfixes, works with Beta 1.3 (0.4.1)
    • Oh god, now you can spawn creepers (and other mobs) (0.4)
    • Fractional percentage chances such as 0.01% are valid (0.4)
    Version 0.3

    • Conforms to new plugin standards and breaks backwards compatibility (0.3)
    Version 0.2

    • Can now drop multiple items per block (0.2.5)
    • Fixed bug introduced in 0.2.3 (0.2.4)
    • Can now specify color of dropped item for wools and dyes (0.2.3)
    • Once again (and hopefully for the last time) fixed durabilities (0.2.2)
    • Changed to lowest priority, hopefully for better compatibility (0.2.2)
    • Fixed durability bug (0.2.1)
    • Change to config.yml format (0.2)
    • Can now specify multiple drops per block, based on different tools (0.2)
    Version 0.1


    • Added "ALL" selector for tools (0.1.3)
    • Workaround for bug in Bukkit whereby durability and max stack size are mixed up (0.1.3)
    • Added drop probability (0.1.2)
    • Customizable damage on block destruction (0.1.1)
    • First release (0.1)
     
    Steve Cole, g_BonE and tension69 like this.
  2. Offline

    driftgoat

    Just wandering Cyklo if you will be adding a way so that creatures can be killed by fire, drowning and explosion and they will still drop items? Have an option where no tool is required to receive the percentage drop. Also I haven't tested it yet but does shooting arrows at monsters work if bow or arrow is listed under tools?
     
  3. Offline

    cyklo

    Given the number of requests I am getting for events which are not the direct result of a player action, I think I shall be adding a new section called "specials".
    [MERGETIME="1300125274"][/MERGETIME]
    To address driftgoat's other question - killing things with arrows works. The tool is the BOW, however, not the arrow.
    [MERGETIME="1300129872"][/MERGETIME]
    And to enkryptor - 0.6.2 adds leaf decay with the special block definition "SPECIAL_LEAFDECAY". Obviously for this you should not define a tool, and instead start with a - drop: line.
     
  4. Offline

    Vanoi

    I would love for a way to drop a List of Items with a set percentage or one of the listed items with a set percentage.

    Like [Stone, Grass] would drop both stone and grass at the same time and [Stone; Grass] would drop stone or grass but not both.

    How the currently system works is that Default can never drop with a Custom drop which is fine (having an option to have default drop not be ignored would be nice though), but when you have 2 custom drops for the same block you always have a chance of getting both.
     
  5. Offline

    cyklo

    The second syntax is not possible, as the config files are in the native YAML language. Essentially, the first syntax will soon do what you describe for the second.

    This already works - add both your custom drop and the default drop with 100% chance. As for always dropping in pairs for events with less than 100% certainty, well, the probabilities all level out in the end if you do it the current way.
     
  6. Offline

    Vanoi

    Oh well... I was really thinking more about the Saplings and Flints which aren't 100% drops
     
  7. Offline

    cyklo

    Can you explain exactly what you want to happen? I'll see what can be done.
     
  8. Offline

    Vanoi

    I'm not really picky, I think you're doing a great job as it is. I just want to know the option is there if ever we need to use it.

    Here's an example of what I was talking about:

    When you break Gravel, you have a 5% chance of getting both a gravel and flint at the same time, not just one of them. This would allow you to have items drop in pairs which aren't 100% chances.

    When you break Mossy Cobblestone, you have a 5% chance of getting one of the following: Mossy Cobblestone, Cobblestone or Slimeballs. This would allow you to have 3 drops (1 for default, 2 for custom) without them dropping 2 items at the same time.

    The comment about the default drop was just a random thought because if you have 10% chance of getting an apple from a tree the default of sapling can never be dropped along with it unless you replicate it with a custom drop with the same percentage (the probability would increase anyways). I was just thinking it would be nice to have a way to set it so default drops would be unaffected by custom drops chances.
     
  9. Offline

    driftgoat

    Awesome @ cyklo. Just putting out a logical example. Will it look something like this:

    SPECIAL_CREATURE_CREEPER:
    - drop: SULPHUR
    quantity: 2
    chance: 30

    Not sure if that's possible. Not familiar with YAML but just seems Like how it would look. Also will I still be able to add the - tool command in there and still have both effects work independently of each other? Or will I have to add a new line without the special in it so there's two sets of creeper drops?
     
  10. Offline

    enkryptor

    Hmm... it's odd. I made the following settings:
    Code:
            SPECIAL_LEAFDECAY:
                - drop: SAPLING
                  chance: 1
                - drop: APPLE
                  chance: 2
    As far as I understand, I should get 1 sapling and 2 apples from 100 blocks of leaves (roughly).

    I chopped down four trees and got 6 apples and 12 saplings. Why? It seems that saplings percentage wasn't changed from the default one. And I have a supposition that SPECIAL_LEAFDECAY happens a few times with one single block, doesn't it?
     
  11. Offline

    cyklo

    As with all other definitions, if you don't specify something to 100%, then the default drop passes through. Try adding an AIR/100 term to prevent default drops.
     
  12. Offline

    solidsnake916

    I tried this plugin, Sponge dont spawn from zombies, i must had spawned over 400 and had them all die at once, and nothing but feathers. I want the Zombies to drop feathers with a 1% Chance of dropping sponges. Nice plugin as well.

    Code:
    otherblocks:
        GLASS:
          - tool: ALL
            drop: GLASS
        GRASS:
          - tool: ALL
            drop: GRASS
            quantity: 1
            chance: 5
        CREATURE_ZOMBIE:
          - tool: ALL
            drop: SPONGE
            quantity: 1
            chance: 1
     
  13. Offline

    cyklo

    How do you mean "all died at once"? OtherBlocks only covers (with the exception of leaf decay) when a player breaks a thing. If you killed the zombies with fire or explosions or similar, they will act as normal... at the moment.
     
  14. Offline

    solidsnake916

    I tested it without them dieing from sunlight, and fire, or other explosives, killing with hand or swords made it drop the sponge. Thanks, maybe making it so whenever they die no matter what it will work.
    Thanks Very much For this plugin.
     
  15. Offline

    Vard

    Great addon, but it doesn;t seem to work on block super far away from spawn (0,0)
    specifically 3 km away

    scratch that. It seems to vary in fucntionality randomly depending on location, regardless of distance from spawn.

    on one side of the room, it will work. On the other side, it will not.
    I cant seem to tell if there's a specific pattern to it yet.
     
  16. Offline

    cyklo

    Just submitted a pull request to the Bukkit team to try and finally get this boat/minecart thing sorted.
     
  17. Offline

    enkryptor

    You know, I thought I already overrided the defaults with this:
    Code:
    - drop: SAPLING
      chance: 1
    
    since saplings is the only default drop from leaves.. However, when I've added the magic AIR/100 option, it seems to be working properly.
     
  18. Offline

    cyklo

    Yeah, air/100 isn't the most intuitive. There's got to be a better way...

    Essentially, it works like this: when it gets to a block for which you've specified special rules, OtherBlocks looks at each possible drop and rolls the dice. If it's OK, the drop gets added to a list. This continues until all probabilities are checked.

    If there's something in the list, OtherBlocks blocks the default drop and drops the contents of the list instead. If the list is empty, it allows the block to do its default drop. Adding AIR/100 basically forces something to be in the list and prevents the default drop.
     
  19. Offline

    enkryptor

    But my list wasn't empy! It was:
    Code:
            SPECIAL_LEAFDECAY:
                - drop: SAPLING
                  chance: 1
                - drop: APPLE
                  chance: 2
    Why did I have the default drop as well?
     
  20. Offline

    Qwerto227

    Ok, i installed this and tried to make it so that every single hostile mob dropped gold ingots because that is the server currency so i manually inserted each and every one of the mobs and gave them both the default drops plus the gold ingots (is there an easier way of doing this, if not then future addition maybe) at first i got loads of typos and corrected them with permissions typo guide then reloaded the server using permissions, it worked perfectly or at least from the look of the console it did, with not a single error (first time ever since i started running the server). I then edited my Automessages.properties file so that it would tell people, and i reloaded the server again and for some reason this plugin errored (?) off. Something about Java and loader constraint violation and other stuff, none of which makes any sense to me, please help :(.
     
  21. Offline

    cyklo

    Because they only get added to the internal list if the probability checks out.

    If neither get added to the list (because of their probabilities), the list is empty.
     
  22. Offline

    enkryptor

    Oh, I've got it now 8)
     
  23. Offline

    Qwerto227

    ok i restarted my pc and it seems to work consitently now
     
  24. Offline

    solidsnake916

    Don't Know if this is an exploit, but When i have this setup
    Code:
        GLASS:
          - tool: ALL
            drop: GLASS
            quantity: 1
            chance: 100
    Glass Breaks, Glass Is Dropped, Which Works Nicely. But if You use WorldGuard, The Glass will break even if its protected, and not be replaced, is this suppose to happen? Can this be fixed?

    Thanks
     
  25. Offline

    cyklo

    Are there no differences when you play with the priority setting?
     
  26. Offline

    solidsnake916

    verbosity: low
    priority: lowest

    Which i used as default, haven't messed with it, alittle confused on what it does?
     
  27. Offline

    cyklo

    The priority settings lets you try to iron out compatibility issues with other plugins. Low priority plugins are executed first, high last. By putting OtherBlocks at a higher priority, it should see WorldEdit has cancelled the event and not do anything. Values to use are explained in the wiki.

    I posted this reply yesterday which should help towards explaining some of how OtherBlocks works.

    So, example 1 (gravel): that's fine, specify gravel as a 100% chance drop, flint as a 5% chance drop. More than one item can drop at once. If you set flint to 5% only, it will drop and the default gravel will only drop if nothing else drops.

    Example 2: this is something I shall work on.

    Example 3: you have two options:
    • Set just APPLE/10. When it fails 90% of the time, Minecraft will do its own probability check to drop a sapling.
    • Set AIR/100, SAPLING/6.25, APPLE/10. This perfectly replicates the original sapling drop, AND adds an apple drop. However, this method only slightly raises the sapling drop rate, and is probably unnecessary.

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

    DontMakeWaves

    I am running OtherBlocks v0.6.1, on craftbukkit 493 (because some of the other plugins that I use haven't updated yet).
    Code:
        SAND:
            - tool: ALL
              drop: SAND
              chance: 100
            - tool: ALL
              drop: LOG
              chance: 0.01
            - tool: ALL
              drop: STICK
              quantity: 10
              chance: 0.1
            - tool: ALL
              drop: BOWL
              chance: 0.01
            - tool: ALL
              drop: IRON_SPADE
              chance: 0.01
            - tool: ALL
              drop: STONE
              chance: 0.01
            - tool: ALL
              drop: WOOD
              chance: 0.01
            - tool: ALL
              drop: GOLD_ORE
              chance: 0.01
            - tool: ALL
              drop: IRON_ORE
              chance: 0.01
            - tool: ALL
              drop: LEAVES
              chance: 0.01
            - tool: ALL
              drop: SPONGE
              chance: 0.01
            - tool: ALL
              drop: GLASS
              chance: 0.01
            - tool: ALL
              drop: LAPIS_ORE
              chance: 0.01
            - tool: ALL
              drop: NOTE_BLOCK
              chance: 0.01
            - tool: ALL
              drop: CLAY_BRICK
              quantity: 4
              chance: 0.01
            - tool: ALL
              drop: OBSIDIAN
              chance: 0.01
            - tool: ALL
              drop: MOB_SPAWNER
              chance: 0.001
            - tool: ALL
              drop: CHEST
              chance: 0.01
            - tool: ALL
              drop: DIAMOND_BLOCK
              chance: 0.01
            - tool: ALL
              drop: SIGN
              chance: 0.01
            - tool: ALL
              drop: LADDER
              chance: 0.01
            - tool: ALL
              drop: RAILS
              chance: 0.01
            - tool: ALL
              drop: REDSTONE_ORE
              chance: 0.01
            - tool: ALL
              drop: CLAY
              chance: 0.01
            - tool: ALL
              drop: SOUL_SAND
              chance: 0.01
            - tool: ALL
              drop: JACK_O_LANTERN
              chance: 0.01
            - tool: ALL
              drop: APPLE
              chance: 0.01
            - tool: ALL
              drop: BOW
              chance: 0.01
            - tool: ALL
              drop: ARROW
              chance: 0.01
            - tool: ALL
              drop: COAL
              chance: 0.01
            - tool: ALL
              drop: DIAMOND
              chance: 0.01
            - tool: ALL
              drop: WOOD_SWORD
              chance: 0.01
            - tool: ALL
              drop: STRING
              chance: 0.01
            - tool: ALL
              drop: FEATHER
              chance: 0.01
            - tool: ALL
              drop: SULPHUR
              chance: 0.01
            - tool: ALL
              drop: LEATHER_HELMET
              chance: 0.01
            - tool: ALL
              drop: CHAINMAIL_HELMET
              chance: 0.01
            - tool: ALL
              drop: CHAINMAIL_CHESTPLATE
              chance: 0.01
            - tool: ALL
              drop: CHAINMAIL_LEGGINGS
              chance: 0.01
            - tool: ALL
              drop: CHAINMAIL_BOOTS
              chance: 0.01
            - tool: ALL
              drop: GRILLED_PORK
              chance: 0.01
            - tool: ALL
              drop: GOLDEN_APPLE
              chance: 0.01
            - tool: ALL
              drop: BUCKET
              chance: 0.01
            - tool: ALL
              drop: SADDLE
              chance: 0.01
            - tool: ALL
              drop: BOAT
              chance: 0.01
            - tool: ALL
              drop: PAPER
              chance: 0.01
            - tool: ALL
              drop: BOOK
              chance: 0.01
            - tool: ALL
              drop: SLIME_BALL
              chance: 0.01
            - tool: ALL
              drop: EGG
              chance: 0.05
            - tool: ALL
              drop: COMPASS
              chance: 0.01
            - tool: ALL
              drop: WATCH
              chance: 0.01
            - tool: ALL
              drop: RAW_FISH
              chance: 0.01
            - tool: ALL
              drop: COOKED_FISH
              chance: 0.01
            - tool: ALL
              drop: GOLD_RECORD
              chance: 0.01
            - tool: ALL
              drop: GREEN_RECORD
              chance: 0.01
            - tool: ALL
              drop: CREATURE_SPIDER
              chance: 0.01
            - tool: ALL
              drop: CREATURE_PIG_ZOMBIE
              chance: 0.002
            - tool: ALL
              drop: CREATURE_SQUID
              chance: 0.005
    
        DIRT:
            - tool: ALL
              drop: DIRT
              chance: 100
            - tool: ALL
              drop: CREATURE_PIG_ZOMBIE
              chance: .001
    When I dig away some sand, and I place a block there other than sand, when I break that block which I placed, it drops the item or items that should have been droped from breaking sand, rather than, for example, droping cobblestone from cobblestone block. This bug doesn't seem to happen in every area, but when I find an area where it does happen, I can duplicate it there every time. This also happens with dirt as well; I'm guessing it happens with blocks that are set to 100% chance.
     
  29. Offline

    Kerpawr

    This plug-in sounds amazing, but I cannot get it to work AT ALL.

    I get this:
    2:10:19 [SEVERE] Could not load plugins/otherblocks.jar in plugins: null
    org.bukkit.plugin.InvalidPluginException
    at org.bukkit.plugin.java.JavaPluginLoader.loadPlugin(JavaPluginLoader.java:113)
    at org.bukkit.plugin.SimplePluginManager.loadPlugin(SimplePluginManager.java:159)
    at org.bukkit.plugin.SimplePluginManager.loadPlugins(SimplePluginManager.java:107)
    at org.bukkit.craftbukkit.CraftServer.loadPlugins(CraftServer.java:61)
    at net.minecraft.server.MinecraftServer.e(MinecraftServer.java:204)
    at net.minecraft.server.MinecraftServer.a(MinecraftServer.java:191)
    at net.minecraft.server.MinecraftServer.d(MinecraftServer.java:131)
    at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:246)
    at net.minecraft.server.ThreadServerApplication.run(SourceFile:366)
    Caused by: while scanning for the next token
    found character '\t' that cannot start any token
    in "<reader>", line 4, column 1:
    - tool: [WOOD_HOE, STONE_HOE, I ...
    ^

    at org.yaml.snakeyaml.scanner.ScannerImpl.fetchMoreTokens(ScannerImpl.java:360)
    at org.yaml.snakeyaml.scanner.ScannerImpl.checkToken(ScannerImpl.java:183)
    at org.yaml.snakeyaml.parser.ParserImpl$ParseBlockMappingValue.produce(ParserImpl.java:592)
    at org.yaml.snakeyaml.parser.ParserImpl.peekEvent(ParserImpl.java:163)
    at org.yaml.snakeyaml.parser.ParserImpl.checkEvent(ParserImpl.java:148)
    at org.yaml.snakeyaml.composer.Composer.composeNode(Composer.java:132)
    at org.yaml.snakeyaml.composer.Composer.composeMappingNode(Composer.java:230)
    at org.yaml.snakeyaml.composer.Composer.composeNode(Composer.java:160)
    at org.yaml.snakeyaml.composer.Composer.composeDocument(Composer.java:122)
    at org.yaml.snakeyaml.composer.Composer.getSingleNode(Composer.java:105)
    at org.yaml.snakeyaml.constructor.BaseConstructor.getSingleData(BaseConstructor.java:124)
    at org.yaml.snakeyaml.Yaml.load(Yaml.java:264)
    at org.bukkit.util.config.Configuration.load(Configuration.java:73)
    at org.bukkit.plugin.java.JavaPlugin.initialize(JavaPlugin.java:149)
    at org.bukkit.plugin.java.JavaPluginLoader.loadPlugin(JavaPluginLoader.java:111)
    ... 8 more


    My config look only like this now:

    otherblocks:

    LEAVES:
    - tool: [WOOD_HOE, STONE_HOE, IRON_HOE, DIAMOND_HOE, GOLD_HOE]
    drop: APPLE
    quantity: 1


    Any ideas? I'm running the server on a Mac.
     
  30. Offline

    Celtic Minstrel

    @Kerpawr - It's an error in your config file; you need to replace all the tabs with spaces.

    This is a nice plugin. I have a lot of suggestions and ideas, though.
    • First, special tool keywords ANY_HOE, ANY_PICKAXE, etc. I know you can just list all five hoes, but this would be more convenient.
    • Second, drop can be CONTENTS for blocks that are containers. I think this covers chests, dispensers, furnaces, and possibly jukeboxes. Though it seems redundant for chests since they already drop their contents. I've done this; it's not hard. I can show you the code if you like.
    • Boats and minecarts... until a VEHICLE_DESTROY event is implemented, can't you just hook into VEHICLE_DAMAGE instead?
    • Keywords COCOA_BEANS for brown dye and LAPIS_LAZULI for dark blue dye would be nice; also BONE_MEAL for white dye, and possibly CACTUS_GREEN, ROSE_RED, DANDELION_YELLOW for the respective dyes. This makes the intention more obvious when I set cocoa beans to be dropped from leaves with a 5% chance.
    • Might be nice to be able to provide weights instead of percentages. As an example of what I mean, if you want leaves to drop cocoa beans one-fifth of the time, apples one-fifth of the time, and saplings three-fifths of the time, you could set the drop weights to 1, 1, and 3; then it adds up the weights of all possible drops to use as the denominator. Easier than needing to work out the percentages for complex setups, though the percentage method works just fine.
    • An entry for REDSTONE_ORE should automatically add an identical one for GLOWING_REDSTONE_ORE. Similarly, FURNACE should also add GLOWING_FURNACE, REDSTONE_TORCH should add for both REDSTONE_TORCH_ON and REDSTONE_TORCH_OFF, SIGN should add for both WALL_SIGN and SIGN_POST, DIODE_BLOCK should add for both DIODE_BLOCK_ON and DIODE_BLOCK_OFF. The user should not need to know that each of these blocks comes in two varieties.
    • A way to make birch logs, pine/redwood logs, and charcoal drop, as well as steps and double steps that are not stone. For charcoal I'd suggest just making a special alias CHARCOAL, but for wood you could use the proposed TreeSpecies keywords, and for steps you could just use the Material keywords (STONE, COBBLESTONE, WOOD, SANDSTONE).
    • A way to make the drop (and the tool) depend on the data value for logs, wool, and steps. For example, to make birch logs drop paper with a 5% chance, or to make wooden half steps mineable with axes instead of pickaxes, or to make each colour of wool drop something different.
    • This is likely not possible, but perhaps a way to control how long it takes to mine the block in each case?
    • A way to control whether ice turns into water. I think if you cancel the BLOCK_BREAK event, it won't turn into water, but if you don't cancel it, it (usually) will. (It would be interesting to extend this to lava... break obsidian with a lighter and it turns into lava! Not terribly useful though.)
    • Exceptions in tools (ie, drop this if mined by any tool other than the listed ones). For example, make bookshelves drop bookshelves if mined by an axe, but three books if mined by anything else.
    • Ability to specify dropping just one of a list of items, but with a different percent chance for each one. For example, leaves dropping either apples (5% chance), cocoa beans (5% chance), golden apples (0.5% chance), or saplings (10% chance), but never two of them at the same time.
    • Specify EXPLOSION as a tool to change what a block drops when it is destroyed by TNT/Creeper/Fireball.
    • Add "attacker:" option for mob drops to check who's attacking; it should allow mob names, PLAYER, or ANY.


    Also! From the wiki: "every line is indented by at least four spaces, not tabs" - I believe one or two spaces will suffice; I habitually indent my YAML files with two spaces, because it's closer to using tabs (which I prefer) while still being a decent-sized indent.
     
  31. Offline

    cyklo

    Blimey, huge amounts of suggestions! Thank you. I'm not typically the creative sort (hence me writing plugins rather than playing the game).

    I shall address them:

    Added this to the issues tracker as "synonyms" functionality.

    Makes sense. Although I'm surprised this does not exist in Minecraft already. Sounds more like a bugfix on the Mojang end - but I guess that's why we're all here already. Added to tracker.

    The problem with hooking into VEHICLE_DAMAGE is that there is no way of reading the current "damage level" - all this is reported on the event is the "damage dealt in this instance". There are two ways around this - either track damage internally (what if there are more resilient vehicles in the future?) or hooking directly into the net.minecraft.server classes (copyright danger!)

    I'm trying to keep my plugins as close to the API as possible, such that if I stop working on them, they should be stable for a long while, and contain little undocumented stuff for a subsequent forker.

    Kind of averse to using made-up names for items when perfectly good descriptions already exist, e.g. "drop: DYE" and "color: BROWN" in this instance.

    A problem with this current functionality is that the current system allows the original drop to occur of all probabilities fail. If there is no fixed sum of denominators, at what proportion are original drops allowed?

    I do kind of regret using percentages instead of standard [0,1] probability ranges, but I'm unsure as to how many people are using my plugin and would prefer not to break backwards compatibility.

    Absolutely. See the "synonyms" comment above.

    I've already pushed a patch to allow the use of the "color:" argument to pass any raw data values if a color Enum is not valid. When the wood/half-height-block/coal enums get added, they will be given textual values.

    An issue which I see at the moment is not being able to discriminate between different block subtypes at the time of breaking. I've added this to the tracker.

    Same as previous.

    Kind of. My plugin ToughBlocks can add a >1 multiplicative value to the number of "breaks" required, but I've not seen a clean way of reducing this to less than one break iteration.

    Already do override the BLOCK_BREAK event and it still occurs. Probably a messy way of doing this with BLOCK_PHYSICS though.

    Sort of already occurs, but it's inclusive rather than exclusive (define a drop for the axes first, then "all" subsequently). This functionality unfortunately disappeared when I added the option to drop multiple blocks. Might add some kind of "exclusivity" flag.

    I will add "one of a list" at a fixed probability for concise settings files, but I don't understand why items with different probabilities need to be set exclusively - it's not exactly unphysical. Again, there is also the problem with summations > 100% which would need to be checked.

    Will be added as one of the specials.

    Will be added as one of the above specials, presumably by checking subtypes of entityDamageByEntity event instances.
    Yes, I know :) Those that are familiar with YAML can do what they like and it will function. Those that aren't should find an exact instruction easier to comprehend than "2 or 4 or doesn't really matter"!

    Thanks very much for your feedback. I've added a number of issues to the tracker. If you feel I've skipped over any or want to embellish them, feel free. Also if you want to push patches - feel free too!
     

Share This Page