[MECH/FIX] NormalizedDrops v1.0.2 - Nerf Monster Traps [1000]

Discussion in 'Inactive/Unsupported Plugins' started by Verrier, May 2, 2011.

  1. Offline

    Verrier

    NormalizedDrops - Nerf Monster Traps
    Version: v1.0.2

    All further updates will be located at: http://dev.bukkit.org/server-mods/normalized-drops/


    NormalizedDrops is a simple little plugin that will limit the amount of loot that can be obtained by giant monster traps and farms. It works by keeping track of where entities die, and if certain thresholds are met, it will remove the loot from that drop.

    There should be very little overhead with tracking entity death as old deaths (older than timeFactor set in the config) will be removed, I haven't found the perfect numbers yet, but the defaults I've included in my config cut my mob spawner output in half, you can easily increase them as you see fit.

    In order to reduce output, I would increase the timeFactor to store deaths longer, or decrease the minDeaths or maxDeaths.Loot will never be rewarded above maxDeaths.

    Keep in mind this plugin is designed simply to slow down loot drops in mob spawners, not to change spawn rate or break them entirely. I wanted people to have the illusion that their trap is working as expected. People put a lot of effort into making their traps, that should be rewarded, but not at the extreme economy breaking rate that happens by default.

    Features:
    • Limit the amount of loot obtained by killing mobs in a certain radius
    • Only tracks deaths when loot is dropped
    • Disable monster spawns nearby after too many loot drops (Added in v1.0.2)
    • Per world configuration values (Added in v1.0.2)
    Download:
    If you do not download the zip with config, you should create a config file manually based upon the example. The plugin will use default settings, but you may want to adjust the numbers to provide more nerfage than is done by default.

    Note: The plugin will not create the config file by default, you must download / create one if you want to alter the settings, but the plugin will work without a config.


    Source Code:

    Commands:
    • /ndrop reload - Reload the configuration file
    Example Config:

    Issues, Bugs, and Features:
    Please post all issues and feature requests on the github issue page:

    Changelog:
    Version 1.0.2
    [FONT=arial]- Added per world configuration settings[/FONT]
    [FONT=arial]- Debug messages are now on by default, add debug: false in your config to disable (per world)[/FONT]
    [FONT=arial]- Added the ability to cancel monster spawns (disableSpawns: true in config, false by default)[/FONT]
    - Config format changed, so updating to 1.0.1 -> 1.0.2 you will need to redo your config.
    Version 1.0.1
    - Increased event priority to High to play better with other drop altering plugins
    Version 1.0.0
    - Initial Release
     
  2. Offline

    Plague

    Is it just me or is the big bold font blurry ?
     
  3. Offline

    jamescosten

    Looks fine to me
     
  4. Offline

    cholo71796

    Your browser's probably zoomed out a little (use ctrl + scroll wheel to adjust). I've noticed you despise formatting that's not the default formatting :D. Well, to each his own, I suppose.
     
  5. Offline

    Phaedrus

    Excellent plugin.

    Question though.... will it work with DropBonus?
     
  6. Offline

    Verrier

    I have no idea, it's on priority Normal, so assuming DropBonus is playing well and is on "lowest" or "low", I would say yes. Give it a shot and let me know? Or if DropBonus is open source, could look at the source and see what priorities it's using.

    Edit: Just looked at the DropBonus source, it appears it's listening on normal also. I'll bump this up to high (which it probably should be anyway since it's extremely specialized) in 1.0.1 so it'll provide consistent behavior. I'll upload a new version shortly

    Edit 2: New version (1.0.1) uploaded with "High" priority, that one should with DropBonus. Untested though
     
  7. Offline

    goldseed

    Thanks a lot... This is very useful.
     
  8. Offline

    Pontus Lantz

    @Verrier
    I tried this out with dropbonus installed and it didn't work. Atleast that is if i understand the settings correct.
    I had the settings below and still got drops from kill number 11,12 and 13 when i stood and killed Zombies inside a mobspawner room. Did not get any messages from this plugin in my log either.
    Code:
    minDeaths: 4 #Minimum number of allowed deaths before loot normalization
    maxDeaths: 10 #Any deaths more than this will be 0 drops, but also the closer this is to minDeaths, the rarer loot will be
    timeFactor: 600 #How long before deaths expire in seconds
    radius: 15 #How close entity deaths need to be before considered nearby (radius in blocks)
    debug: true #Log debug messages when loot is normalized
     
  9. Offline

    link2110

    keeping an eye on this, may use it later.
     
  10. Offline

    Verrier

    It only tracks the kills when loot is actually dropped... I should probably make that more clear. Think of it more like "I only want there to be a maximum 10 loot drops in 10 minutes". So it's not directly the number of kills if that's what you were counting. Hope that helps clarify!

    It might be possible that DropBonus isn't playing well with it (like if it clears the drops instead of setting them, this plugin would never detect it as having drops, but that would be a silly way to do it). I can look into how DropBonus works further if you say, kill 50 zombies and still get nothing, but I would expect it to still display the messages in the log when it normalizes loot, just any special drops that DropBonus gives would still drop... but it SHOULD work

    Here's an example from the log on my server:
    Code:
    2011-05-06 15:08:38 [INFO] [NormalizedDrops] Normalized drop at -2466.57,18.20,-2486.78 (Entity: CraftZombie, NearbyDeaths: 10 > RND: 6, TrackerSize: 109)
    2011-05-06 15:08:43 [INFO] [NormalizedDrops] Normalized drop at -2466.41,18.20,-2486.33 (Entity: CraftCreeper, NearbyDeaths: 11 > RND: 7, TrackerSize: 111)
    2011-05-06 15:08:56 [INFO] [NormalizedDrops] Normalized drop at -2466.56,18.15,-2486.83 (Entity: CraftCreeper, NearbyDeaths: 11 > RND: 6, TrackerSize: 110)
    2011-05-06 15:09:04 [INFO] [NormalizedDrops] Normalized drop at -2466.26,18.20,-2486.70 (Entity: CraftSkeleton, NearbyDeaths: 11 > RND: 6, TrackerSize: 110)
    2011-05-06 15:09:10 [INFO] [NormalizedDrops] Normalized drop at -2466.15,18.20,-2486.70 (Entity: CraftSkeleton, NearbyDeaths: 11 > RND: 4, TrackerSize: 111)
    2011-05-06 15:09:15 [INFO] [NormalizedDrops] Normalized drop at -2466.57,18.20,-2486.78 (Entity: CraftSkeleton, NearbyDeaths: 11 > RND: 10, TrackerSize: 109)
    
    The debug message is formatted as such:

    X,Y,Z location: Where the mob died
    Entity: What entity died
    NearbyDeaths: How many deaths there have been nearby in the past timeFactor seconds
    RND: The random number used to gracefully slow down drops the closer it gets to maxDeaths
    TrackerSize: How many total death locations are being tracked
     
  11. Offline

    Pontus Lantz

    @Verrier
    Hmm i didn't get any logging from NormalizedDrops at all and i have quite many drops on my loottable and got atleast 15 drops on that time. So i guess it's dropBonus that does it in a other way. I'll do some more testing.

    Edit: Change my settings to Min 2 and Max 4 and after 5 kills and 7 drops still no message in the log
     
  12. Offline

    Verrier

    Booo, alright. Looks like I'll have to install / look into DropBonus more... see if it's even possible to cancel it's drops at all. Thanks for the report, let me know if you uncover anything else
     
  13. Offline

    Pontus Lantz

    @Verrier
    Im using the override function btw. Which makes the original loots be overwrited.
    Just thought i might matter in some way ^^
     
  14. looks like you need glasses :D
    that, or your browser is screwed up. oh well...
     
  15. Offline

    Verrier

    Yeah, I just checked the source:
    https://github.com/tkekd538/DropBon...tener/entity/DropBonusEntityListener.java#L79

    When you use override it clears the drops entirely, so my plugin will never see the drops. Even if I change it to track deaths instead of drops, I'm not seeing a way to alter the items DropBonus spawns into the world since it spawns them into the world outside of the event (https://github.com/tkekd538/DropBon...g/minecraft/util/DropBonusEvaluator.java#L329)

    Ideally it would add / replace the drops in the event itself, but that's unfortunately that's not how it's coded.

    Sorry! No DropBonus support unless the DropBonus author alters the way he handles drops.
     
    jasonznack likes this.
  16. Offline

    Pontus Lantz

    @Verrier
    Naaw. Sadly dropBonus seems to be very inactive atm :(
     
  17. Request: Multi-world support, separate config per world.
     
  18. Offline

    Verrier

    Good call, I'll look into this once 1.6 comes out and Bukkit finalizes / stabilizes their multiworld support for Notch's Nether and such.
     
  19. Offline

    Juze

  20. Offline

    Verrier

    Thanks :)

    That's a good alternative if you want to completely break monster traps / farms... but a lot of people put some effort into making their traps, I didn't want to break them entirely, just a subtle nerf. But if anyone is wanting to completely break them, use that plugin!

    Also my plugin will nerf drops if a player kills too many mobs in the same area, forcing players to actually spread out / go out and hunt mobs instead of farming in one area.
     
  21. Offline

    Grimmy777

    Is there any chance of you making an offshoot of this what slowly limits the amount of mobs that spawn in a loaded chunk based of off how many have been killed there recently? I am using this right now but I want to make a hunter class and if players can make mobs spawn a will and kill them from a safe spot, then the hunter class would be pointless. Thanks for the great mod!
     
  22. Offline

    Verrier

    Sorry it took so long, I've been super busy over the past couple days.


    Added in 1.0.2, along with per world debug settings. If you update you'll have to fix your config

    I added spawn a canceling option in 1.0.2, it still tracks by loot drops, not by exact kills... it's possible to make this an option I suppose, but I think loot drops should work just fine in most cases. It also uses the same minDeath and maxDeath numbers and will slowly (randomly) cancel the spawns. There is a debug message letting you know when it's canceled.
     
  23. Offline

    Grimmy777

    so after a while the mobs would stop spawning as it is right now?
     
  24. Offline

    Verrier

    Sort of, if you make your config like this:

    Code:
    world:
        minDeaths: 1
        maxDeaths: 1
        timeFactor: 600
        radius: 50
        debug: true
        disableSpawns: true
    No monsters should spawn within 50 blocks of the first monster you kill that drops loot for 10 minutes, and everytime a monster tries to spawn, it will output a message saying it normalized the spawn (that's what debug: true) does.

    Any existing monsters in the area will still be there, it doesn't remove them or anything, that option just prevents monsters from spawning in the instances it would remove drops from monsters.
     
  25. Offline

    sukosevato

    Works great! thanks for the excellent plugin!
     
  26. I get stuff like:

    y: CraftSquid, NearbyDeaths: 24 > RND: 17, TrackerSize: 26)
    2011-09-05 21:29:25 [INFO] [NormalizedDrops] Normalized drop in world_mdr @ -46.49,2.00,63.85 (Entity: CraftSquid, NearbyDeaths: 22 > RND: 17, TrackerSize: 26)
    2011-09-05 21:29:32 [INFO] [NormalizedDrops] Normalized drop in world_mdr @ -45.19,2.00,62.49 (Entity: CraftSquid, NearbyDeaths: 20 > RND: 12, TrackerSize: 26)

    But I don't even have a config entry for that world, default is not disabled?
     
  27. Offline

    Verrier

    Oops, it looks like that if the world isn't in the config it's using the default values (so yes, it's enabled by default).

    You can easily disable that by doing something like
    Code:
    world_mdr:
        timeFactor: 1
    That should make all drops expire after 1 second, might be able to even use 0 so they expire instantly.

    I'll try and make a update within the next week or two so that it's a little more intuitive and easier to use soon. Sorry for any confusion!
     
  28. Also, from my experience, reloading the config with the command, doesn't actually update ingame. I switched disableSpawns live, reloading config, but it kept using the old setting until restart.
     
  29. Offline

    Cristof

    hi!
    Thx for ur wonderful plugin!
    It's possible to specific a chunk where normalizedrop does't work??:D
     
  30. Offline

    Verrier

    I doubt there will ever be the ability to exclude a specific chunk, what's your use case for that? I can't quite picture why that would be needed :(
     

Share This Page