An event even before protocol version is checked
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 2.3k
- Forks
- 959
- Avg merge
- 5d 10h
- Merged PRs (30d)
- 2
Description
Requested Feature
I'd like to have an event that is even triggered before the protocol version check here: https://github.com/PaperMC/Velocity/blob/5154f029108e3d3ba804b9d4555903347f2376c2/proxy/src/main/java/com/velocitypowered/proxy/connection/client/HandshakeSessionHandler.java#L127
Why is this needed?
So that incompatibilities in the protocol version can be checked within the plugin and handled accordingly. Currently, it is not possible to modify the message that is sent on a too recent protocol version within plugins. I'd like to specify an allowed range of versions and display a unified message on either too new versions or too old versions.
Alternative Solutions
Optionally, the check could be moved below the HandshakeEvent.
Additional Information
No response
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at proxy/src/main/java/com/velocitypowered/proxy/connection/client/HandshakeSessionHandler.java around line 127 and trace the existing HandshakeEvent and protocol-version check. Determine where a pre-check event could expose the version decision to plugins. Done means plugins can handle too-old and too-new protocol versions and provide a unified message.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- networking
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100