SilkMC / silk

Silk is a Minecraft API for Kotlin - targetting Fabric, Quilt and Paper
https://silkmc.net/silk/docs/
GNU General Public License v3.0
100 stars 12 forks source link

network: Use custom payload packets and separate channels #48

Closed jakobkmar closed 1 year ago

jakobkmar commented 1 year ago

This removes the usage of fabric-api from silk-network. Therefore the module no longer depends on fabric-api at all.

Instead, silk-network now sends custom payload packets directly. Each packet will now be sent on a channel of the same name as the packet identifier.

Client to client packets can now be forwarded to multiple players at once.

It is now garuanteed that receivers won't be executed concurrently.

mooziii commented 1 year ago

Does this introduce breaking changes to existing code? If yes, what would be the new method of sending and receiving packets

jakobkmar commented 1 year ago

Normal existing code won't be affected by this.

The following might break some code: