Custom Drops [please :)]

Discussion in 'Archived: Plugin Requests' started by Euphoriant, Jan 19, 2011.

?

Would you use a plugin that allowed you to customize the drop/drop-rate of every block type?

  1. I've been waiting for a plugin for that!

    54.1%
  2. Yeah, that sounds interesting.

    32.4%
  3. I like the current drops.

    10.8%
  4. Cake is delicious.

    35.1%
Multiple votes are allowed.
  1. Offline

    Euphoriant

    Well, I've been seeing plugins released that change the drops of specific items. There was Excess Lapis, now theres the egg throwing one that makes eggs hatch different mobs when thrown. There are probably one or two others as well.

    What I would like is an all-around plugin that would allow me to customize the drop/drop-rate of each blocktype in the game, including mob drops. For instance, I would like to punch leaves off a tree and not only receive saplings, but also receive apples, sticks, and even leaf blocks. Dirt could hold a plethora of drops, imagining all the items that get dropped and then vanish after a while, so you could make dirt have a low chance to drop misc. items like mushrooms, sticks, or perhaps an ultra rare chance to drop something like a compass or a watch.

    There was a plugin for hMod simply called CustomDrops which did most of this. The one thing it did not alter was mob drops. However, a MobDrops plugin was eventually released as well.

    Here is my customdrops.txt in it's entirety which served as the configuration file, if it helps to explain what I'm talking about:

    Code:
    # Author: Nilaky
    #
    # Preface all commented lines with #
    # All other lines should be in the form:
    # blockID:drop1,drop2,drop3:probability
    # CustomDrops is designed to replace existing drops!
    # For example:
    # 2:295:0.5
    # will make grass(2) drop seeds(295) 50% of the time
    # but this replaces the dirt that would drop
    # To keep the old drops, try something like:
    # 2:295:0.5
    # 2:3:1.0
    # this makes grass(2) always drop dirt(3)
    # but have a 50% chance to ALSO drop seeds(295)
    
    
    
    # Sand
    12:12:1.0
    12:20:0.001
    12:346:0.0001
    
    
    # Leaves
    18:6:0.05
    18:18:0.15
    18:280:0.1
    18:260:0.025
    18:322:0.0001
    
    #cloth
    35:287:0.75
    35:287:0.50
    35:287:0.25
    
    
    # Ice
    79:79:0.75
    
    
    # Glass
    20:20:0.75
    
    
    # Halfblocks
    43:44,44:1.0
    
    
    # Bookshelves
    47:340,340,340,5,5,5:1.0
    
    
    # Gold
    14:266:1.0
    14:266:0.1
    14:41:0.01
    14:1:1.0
    
    
    # Coal
    16:264:0.0001
    16:263:1.0
    16:263:0.1
    16:263:0.01
    16:1:0.25
    
    
    # Diamond
    56:264:1.0
    56:264:0.009
    56:57:0.005
    56:1:1.0
    
    
    # Grassy Dirt
    2:2:0.1
    2:3:1.0
    2:295:0.01
    2:262:0.0001
    2:318:0.001
    2:301:0.0001
    2:280:0.010
    2:39:0.05
    2:40:0.001
    
    
    # (Bitch ass)Hoe'd Dirt
    60:262:0.005
    60:263:0.001
    60:280:0.01
    60:302:0.0004
    60:318:0.01
    60:318:0.01
    60:295:0.1
    60:288:0.01
    60:287:0.01
    60:281:0.01
    60:336:0.01
    60:340:0.01
    60:337:0.01
    60:345:0.0005
    60:266:0.0001
    
    
    
    
    # Dirt
    3:3:1.0
    3:262:0.001
    3:263:0.0001
    3:280:0.001
    3:302:0.00005
    3:318:0.005
    3:318:0.005
    
    
    # Wooden Stairs
    53:53:1.0
    
    
    # Cobble Stairs
    67:67:1.0
    
    
    # Mobspawner
    52:306:0.05
    52:307:0.05
    52:308:0.05
    52:309:0.05
    52:310:0.005
    52:311:0.005
    52:312:0.005
    52:313:0.005
    52:320,320:0.09
    52:320,320,320:0.09
    52:264,264,264:0.01
    52:266,266:0.05
    52:266,266,266:0.03
    52:267:0.08
    52:276:0.005
    52:283:0.05
    52:302,303:0.1
    52:304,305:0.09
    52:331,331,331,331,331:0.05
    52:314:0.03
    52:315:0.03
    52:316:0.03
    52:317:0.03
    52:348,348,348:0.05
    52:348,348:0.05
    52:322,322,322:0.05
    52:289,289,289,289,289:0.05
    52:350,350,350:0.09
    52:262,262,262,262,262,262,262,262,262,262:0.05
    52:50,50,50,50,50:0.1
    52:261:0.05
    52:259:0.05
    
    
    # Snow
    78:78:1.0
    
    
    # Gravel
    13:13:0.4
    13:318:0.15
    13:318,318:0.09
    13:263:0.009
    13:15:0.001
    Notice that Mob Spawners can drop some phat lewts. That was pretty much our workaround to not being able to edit mob drops at the time.

    Anyways, I hope to see you brilliant son's'a'bitches churn our some killer plugins!
     
  2. Offline

    Snowl

    How quick do you need this? I made a quick version but it only has one custom drop per block, and no percentages, and a slightly different layout of configuration file...
    It's currently
    Code:
    46=1
    1=1
    25=3
    36=3
     
  3. Offline

    Euphoriant

    I dont really need this quick. Knowing that it is, or will be available is good enough. I do, however, prefer the slightly more detailed setup with percentages and whatnot.
     
  4. Offline

    Snowl

    Almost got percentages, but for some strange reason its proccing randomly instead of the percentage... haha.

    Fixed. Was using < instead of > and didn't realise >_>

    Might as well upload an alpha version. I'm not sure how you like your percentages, is 1% proccing too often? Only one custom drop though.

    Accidentally uploaded a version which had debugging >_> should be fixed.
     

    Attached Files:

    Last edited by a moderator: May 6, 2016
  5. Offline

    M1sT3rM4n

    High five! Was waiting for mob dropping for the longest time :p
     
  6. Offline

    Snowl

    It doesn't have mob dropping yet, sorry :(
     
  7. Offline

    M1sT3rM4n

    Damn.... maybe you can put it in ;)
     
  8. Offline

    Snowl

    I'll see, no promises though :p
    --- merged: Jan 20, 2011 11:39 PM ---
    EntityDeath isn't implemented properly, can't do it till then :(
     
  9. Offline

    M1sT3rM4n

    I have all the patience in the world >: )
     
  10. Offline

    Euphoriant

    Well, for my intended use it would be pretty mandatory for blocks to have multiple drops (breaking leaves produces apples, sticks, leaves etc). Percentages are kinda weird and we noticed that we had to REALLY lower percentages on some drops to make it be balanced. If it helps, and if I'm not infringing anything, here is a link to the original CustomDrops post on the hMod forums: http://forum.hey0.net/showthread.php?tid=2372&highlight=customdrops

    And I'll also throw in the most up-to-date customdrops.zip if that code will help at all.

    I gotta say thanks for showing an interest in this request!
    --- merged: Jan 21, 2011 1:48 AM ---
    Does this add a single custom drop to the current drop or does this override the current drop?
     

    Attached Files:

  11. Offline

    barghest

    Got a user on my server who wants me to get this implemented so he can decorate with leaf blocks. Figured I'd throw a "me too" in here. :D
     
  12. Offline

    Snowl

    Currently adds a custom drop. It currently goes from 0 to 100 (0.00 to 1.0). I could make it go from 1 to 1000% if you want (for more control. I will be adding support for more custom blocks (infinite), and hopefully mob drops.

    If anyone wants to attempt to fix it so that you can add more than one custom block, src is included.
     

    Attached Files:

  13. Offline

    Euphoriant

    I believe what we worked with before was a pretty simple scale from 0.00 to 1.0. It seemed incredibly hard to control, as you can see by scanning the config file in the OP. We had to push some values into the hundred-thousandths to get a significantly rare enough drop out of it as seen:

    Code:
    # Dirt
    3:3:1.0
    3:262:0.001
    3:263:0.0001
    3:280:0.001
    3:302:0.00005 <---chainmail helm in the dirt! F-yeah!
    3:318:0.005
    3:318:0.005
    

    Adding a custom drop is totally a good step, but for total awesomeness there needs to be a (possibly) limitless number of custom drops for any single block type.

    By adding support for inf. blocks do you mean *punch block* *get inf. block* or just some method of haxorizing in an inf. block? Or is this what will allow there to be multiple custom drops for the same block? I'm just slightly drunk right now so I might have read your post like a drunkard.

    Mob drops(multiple custom drops per mob)=yes please :)

    And as I said, there is really by no means a time constraint. I just figured that this would be of use to people besides me, and it seemed like a positive request. I wish I had diamond coding gloves so I could write some sweet mods/plugins/etc.
     
  14. Offline

    Snowl

    I mean you can specify
    eg. infinitely
    instead of just one.

    Increased it so the range is 1-10000 and I got a new shovel and dug till it broke and it didn't drop. I don't know how many more I blocks i needed to dig :p. Is that rare enough for you?
     
  15. Offline

    Euphoriant

    Awesome! I wish you much luck in your endeavors.

    What kind of shovel >.> lol

    As long as it's relatively easy to set up a drop-rate, whether it be extremely rare or extremely common, I'm happy. The old format seemed to have some gray-zone where value changes didnt seem to affect much, hence the o.oooo5. Honestly, I'd even take this old confusing format, if it worked :)

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

    Snowl

    diamond. 1 = 0.0001 drop rate. 5000 = 0.5, 10000 = 1
     
  17. Offline

    Euphoriant

    This is quite confusing, sir.
     
  18. Offline

    Snowl

    It is. One second, i'll fix the percentage. Fixed percentage to the CustomDrops percentage system. 1.0 is always drop, 0.5 is half drop rate, etc. You can use 0.0005 now and it will work.
    --- merged: Jan 21, 2011 7:14 AM ---
    The final config SHOULD be something like this:
    Code:
    # Sand
    12=12:1.0
    12=20:0.001
    12=346:0.0001
    
    # Leaves
    18=6:0.05
    18=18:0.15
    18=280:0.1
    18=260:0.025
    18=322:0.0001
    
    #cloth
    35=287:0.75
    35=287:0.50
    35=287:0.25
    
    # Ice
    79=79:0.75
    
    # Glass
    20=20:0.75
    
    # Halfblocks
    43=44,44:1.0
    
    # Bookshelves
    47=340,340,340,5,5,5:1.0
    
    # Gold
    14=266:1.0
    14=266:0.1
    14=41:0.01
    14=1:1.0
    
    # Coal
    16=264:0.0001
    16=263:1.0
    16=263:0.1
    16=263:0.01
    16=1:0.25
    
    # Diamond
    56=264:1.0
    56=264:0.009
    56=57:0.005
    56=1:1.0
    
    # Grassy Dirt
    2=2:0.1
    2=3:1.0
    2=295:0.01
    2=262:0.0001
    2=318:0.001
    2=301:0.0001
    2=280:0.010
    2=39:0.05
    2=40:0.001
    
    # (Bitch ass)Hoe'd Dirt
    60=262:0.005
    60=263:0.001
    60=280:0.01
    60=302:0.0004
    60=318:0.01
    60=318:0.01
    60=295:0.1
    60=288:0.01
    60=287:0.01
    60=281:0.01
    60=336:0.01
    60=340:0.01
    60=337:0.01
    60=345:0.0005
    60=266:0.0001
    
    # Dirt
    3=3:1.0
    3=262:0.001
    3=263:0.0001
    3=280:0.001
    3=302:0.00005
    3=318:0.005
    3=318:0.005
    
    # Wooden Stairs
    53=53:1.0
    
    # Cobble Stairs
    67=67:1.0
    
    # Mobspawner
    52=306:0.05
    52=307:0.05
    52=308:0.05
    52=309:0.05
    52=310:0.005
    52=311:0.005
    52=312:0.005
    52=313:0.005
    52=320,320:0.09
    52=320,320,320:0.09
    52=264,264,264:0.01
    52=266,266:0.05
    52=266,266,266:0.03
    52=267:0.08
    52=276:0.005
    52=283:0.05
    52=302,303:0.1
    52=304,305:0.09
    52=331,331,331,331,331:0.05
    52=314:0.03
    52=315:0.03
    52=316:0.03
    52=317:0.03
    52=348,348,348:0.05
    52=348,348:0.05
    52=322,322,322:0.05
    52=289,289,289,289,289:0.05
    52=350,350,350:0.09
    52=262,262,262,262,262,262,262,262,262,262:0.05
    52=50,50,50,50,50:0.1
    52=261:0.05
    52=259:0.05
    
    # Snow
    78=78:1.0
    
    # Gravel
    13=13:0.4
    13=318:0.15
    13=318,318:0.09
    13=263:0.009
    13=15:0.001
     
  19. Offline

    Euphoriant

    I realize now that I was quite intoxicated at the time of my last post and could not grasp the:

    1 = 0.0001, 5000 = 0.5, 10000 = 1

    This makes sense now! Could it use either number system? Because it kinda seems like each method would potentially be preferential depending on the user. The 0-10000 scale seems like it might be easiest to approach, as the 0.00-1.0 scale seemed rather finicky.

    I've tested v1 on my server (running latest craftbukkit) and I dont believe it is working at all.

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

    Mattdk

    This plugin deserves its own topic, its an awesome idea. Whether or not you can get it to mod monster drops now, I'm sure you'll be able to in the near future.
     
  21. Offline

    Euphoriant

    Agreed.
     
  22. Offline

    Snowl

    Sorry, my internet has been ****ing up and nothing will load. I'm still looking in how to add more drops but since i'm beginning java (from VB.Net :O) it's really strange to me. Maybe a expert could help *hint hint*
    Here's a fixed version with my block properties included. If you have a block say 2=2 it will currently not drop a block.
    You don't need src btw. It's not compiled on the latest version of bukkit, i'll try and dl that now and recompile it if it doesnt work...
    EDIT: Compiled with latest bukkit version. craftbukkit is taking over 30 minutes to download so I can't really test it, sorry. :p
     

    Attached Files:

  23. Offline

    Mattdk

    I'll test this soon on the latest craftbukkit and get back to you here.
     
  24. Offline

    Euphoriant

    Any progress made here?
     
  25. Offline

    Snowl

    Nope, I have no idea on how to add more blocks. I'll keep on looking though :D
     
  26. Offline

    Izbay

    So happy to see something like this! Can't wait for specified mob drops to be functional! :]

    I'm having some issues getting tree leaves to drop from themselves... and I'm not sure of the cause. 18=18:0.25 in my property file doesn't seem to do the trick. >.>
     
  27. Offline

    Snowl

    it's because theres a check to see if there is a block = block, then it doesnt spawn. i forgot to remove it, one sec, let me fix it :p
    --- merged: Jan 25, 2011 8:02 AM ---
    Hmm, got multiple drops working, except it drops every blocks custom block instead of it's (massive sentence fragment)

    It's nice to know theres progress though!
    --- merged: Jan 25, 2011 8:11 AM ---
    HUZZAH! WORKING! :D BLOCKDROPS IS NOW WORKING PROPERLY.
    http://forums.bukkit.org/threads/me...ustomize-the-items-your-blocks-drop-122.2177/
     
  28. Offline

    Izbay

    Huzzah!
     
  29. Offline

    Snowl

    How are you supposed to destroy a mob spawner? anyway heres your customblocks properties into blockdrops: may look strange but oh well:
    Code:
    # Sand
    12;12:1.0;20:0.001;346:0.0001
    
    # Leaves
    18;6:0.05;18:0.15;280:0.1;260:0.025;322:0.0001
    
    #cloth
    35;287:0.75;287:0.50;287:0.25
    
    # Ice
    79;79:0.75
    
    # Glass
    20;20:0.75
    
    # Halfblocks
    43;44:1.0;44:1.0
    
    # Bookshelves
    47:340:1.0;340:1.0;340:1.0;5:1.0;5:1.0;5:1.0
    
    # Gold
    14;266:1.0;266:0.1;41:0.01;1:1.0
    
    # Coal
    16;264:0.0001;263:1.0;263:0.1;263:0.01;1:0.25
    
    # Diamond
    56;264:1.0;264:0.009;57:0.005;1:1.0
    
    # Grassy Dirt
    2;2:0.1;3:1.0;295:0.01;262:0.0001;318:0.001;301:0.0001;280:0.010;39:0.05;40:0.001
    
    # (Bitch ass)Hoe'd Dirt
    60;262:0.005;263:0.001;280:0.01;302:0.0004;318:0.01;318:0.01;295:0.1;288:0.01;287:0.01;281:0.01;336:0.01;340:0.01;337:0.01;345:0.0005;266:0.0001
    
    # Dirt
    3;3:1.0;262:0.001;263:0.0001;280:0.001;302:0.00005;318:0.005;318:0.005
    
    # Wooden Stairs
    53;53:1.0
    
    # Cobble Stairs
    67;67:1.0
    
    # Mobspawner
    52;306:0.05;307:0.05;308:0.05;309:0.05;310:0.005;311:0.005;312:0.005;313:0.005;320:0.09;320:0.09;320:0.09;320:0.09;320:0.09;264:0.01;264:0.01;264:0.01;266:0.05;266:0.05;266:0.03;266:0.03;266:0.03;267:0.08;276:0.005;283:0.05;302,303:0.1;304:0.09;305:0.09;331:0.05;331:0.05;331:0.05;331:0.05;331:0.05;314:0.03;315:0.03;316:0.03;317:0.03;348:0.05;348:0.05;348:0.05;348:0.05;348:0.05;322:0.05;322:0.05;322:0.05;289:0.05;289:0.05;289:0.05;289:0.05;289:0.05;350:0.09;350:0.09;350:0.09;262:0.05;262:0.05;262:0.05;262:0.05;262:0.05;262:0.05;262:0.05;262:0.05;262:0.05;262:0.05;50:0.01;50:0.01;50:0.01;50:0.01;50:0.1;261:0.05;259:0.05
    
    # Snow
    78;78:1.0
    
    # Gravel
    13;13:0.4;318:0.15;318,318:0.09;263:0.009;15:0.001
    --- merged: Jan 25, 2011 10:13 PM ---
    Added creeper drops, but only when they asplode. Use Creeper; instead of a block id/
     

Share This Page