Skip to content

Expose resetFlyingTicks for Player#14016

Open
BitByLogics wants to merge 1 commit into
PaperMC:mainfrom
BitByLogics:feat/reset-flying-ticks-method
Open

Expose resetFlyingTicks for Player#14016
BitByLogics wants to merge 1 commit into
PaperMC:mainfrom
BitByLogics:feat/reset-flying-ticks-method

Conversation

@BitByLogics

Copy link
Copy Markdown

Simply adds a method to Player which exposes the resetFlyingTicks method from ServerGamePacketListenerImpl.

This is particularly useful for preventing the "flying" kick without having event spam. While you could enable the "allow-flight" option in server.properties, I find that allowing developers to have a method to reset this counter themselves would be useful.

For example, my use case is for my PacketBlocks plugin where players standing on them would be kicked for flying. Currently I require you to enable"allow-flight" however understandbly some server owners may not want to do this.

@Bishops-exe Bishops-exe left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Awaiting review

Development

Successfully merging this pull request may close these issues.

2 participants