Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Suggestion] Add options to limit max head drops per X minutes #128

Open
TerdyTheTerd opened this issue Feb 5, 2025 · 2 comments
Open
Labels
enhancement New feature or request

Comments

@TerdyTheTerd
Copy link

Its a common occurrence that players will get multiple heads within a few minutes when they are at their mob farms. It would be nice if there was a simple config option for something like "time-since-last-drop: 5m" which would prevent additional drops for the same mob within the defined "Xm".

@EvModder
Copy link
Owner

EvModder commented Feb 6, 2025

Hmm, there are a couple variations of this to consider, and I really like them all, so I might make an add-on for them:

  • time-alive-multipliers (this one already exists): Can be used to prevent recently spawned mobs from dropping heads.

  • behead-cooldown-multipliers (your suggestion): Per-player, can be used to track their recently beheaded mobs and prevent drops from those mob types.

  • behead-cooldown-multipliers-global: Same as above, but tracks global beheads for a mob type. Useful to avoid players bypassing the cooldown by using alts in a farm. Downside is it might make common heads harder to get on big servers.

  • behead-cooldown-multipliers-area: Solves the global problem by only affecting droprates of mobs in a radius around the previous behead event. This could be interesting, since if you set the time limit to something like 999years with a drop-chance multiplier of 0% you could effectively prevent players from getting more than 1 head per farm built.

  • persistent-cooldown-multipliers: true/false: Saving the recent behead data when the server restarts (currently the plugin forgets everything on restart/reload)

  • time-multiplier-smooth-transitions: true/false: If you have a head drop multiplier set to 0, then set to 1 at 5m like in your example, it would average it out based on the current time, i.e., mobs killed at 2.5m would be 50% less likely to drop a head compared to a 0% chance.

  • target-droprates: This one is fancier / more complicated to code, so I might not include it right away, but the idea is server owners could specify a "target rarity" of specific mobs (e.g., 5 cow heads per month), and the plugin can dynamically adjust rates to create that difficulty.

@TerdyTheTerd
Copy link
Author

I don't like using the time-alive because then naturally spawning mobs from players exploring, or naturally spawning hostile mobs around the players in caves/night will effectively have their head drops disabled. A per-player drop cooldown makes the most sense to me. I think a good way to target mob farms specifically would either be region based, or to simply add/double the multiplier for each consecutive drop, so if a player is at their endermen XP farm and are only killing endermen, it will quickly turn into a 30 minute delay between drops.

@EvModder EvModder added the enhancement New feature or request label Feb 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants