Open WOLFI3654 opened 3 years ago
This must be submitted upstream as to not break API.
Thank you, how exactly do I file an issue on the bukkit/spigot upstream?
@WOLFI3654 you need to go to https://hub.spigotmc.org/jira/projects/SPIGOT/issues/ and create new issue there. For the future, this can be found by googling spigotmc jira
Thanks, I already tried that at some point in time but I had a few issues. I'll see what I can do
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Reported upstream: https://hub.spigotmc.org/jira/browse/SPIGOT-6495
Thank you very much!
Expected behavior
When the EntityBreedEvent is cancelled, their loveTicks should be reset.
Observed/Actual behavior
When cancelling the EntityBreedEvent the two animals will try again every few seconds to produce a baby as long as they are still willing. This results in subsequent calls the EntityBreedEvent. If you cancel this event, your intention is generally to disallow breeding for the two animals, and not to postpone it.
Steps/models to reproduce
A very simple plugin is sufficient to experience this behavior:
Plugin list
Empty; Except plugin to test the EntityBreedEvent cancel behavior.
Paper version
[17:16:49 INFO]: This server is running Paper version git-Paper-575 (MC: 1.16.5) (Implementing API version 1.16.5-R0.1-SNAPSHOT) You are running the latest version Previous version: git-Paper-457 (MC: 1.16.5)
Agreements
Its certainly not a behavior that should be expected when cancelling the event. Tho this can be circumvented by resetting the loveModeTicks manually, just doing it by default when the event is cancelled would be a neat improvement to the api. Its really easy to miss that especially if you are new to plugin development and depending on your use case could result in quite unexpected and unnoticed performance issues.