APDevTeam / Movecraft

The original movement plugin for Paper. Reloaded. Again.
GNU General Public License v3.0
122 stars 74 forks source link

Issue on PlayerListener class #631

Closed SecretX33 closed 1 week ago

SecretX33 commented 4 months ago

I'm almost sure this line is wrong:

https://github.com/APDevTeam/Movecraft/blob/774013ace90033f404e02d7e29d45aa8475bbb26/modules/Movecraft/src/main/java/net/countercraft/movecraft/listener/PlayerListener.java#L107

This check is always true since e is an Event and well, events are never a Player. Also, I think this methods wants to listen for PlayerDeathEvent and not EntityDamageByEntityEvent given its name (onPlayerDeath).

TylerS1066 commented 4 months ago

That's a good catch and explains why that crafts don't sink when the player is killed.

We should just remove that listener, since it's never worked. If somebody does want the feature, we could re-add it and default it to disabled.