extremeheat 8e131c359e
Fix server_data payload for 1.19+, fix kicks messages on 1.20.3+ (#1364)
* Fix server_data payload sent to clients for versions 1.19+

Fixes #1362

Add missing fields to `server_data` payload for versions 1.19+.

* Add `motd` and `icon` fields to `server_data` payload for version 1.19.
* Add `motd`, `icon`, and `enforcesSecureChat` fields to `server_data` payload for version 1.19.2.
* Add `motd`, `icon`, and `enforcesSecureChat` fields to `server_data` payload for version 1.19.3.
* Add `motd`, `iconBytes`, and `enforcesSecureChat` fields to `server_data` payload for versions 1.19.4, 1.20, and 1.20.2.
* Add `motd`, `iconBytes`, and `enforcesSecureChat` fields to `server_data` payload for version 1.20.3.
* Add `motd` and `iconBytes` fields to `server_data` payload for version 1.20.5+.
* Use NBT components for `motd` if `chatPacketsUseNbtComponents` feature is supported.
* Convert `favicon` to buffer for `iconBytes` field if available.

---

For more details, open the [Copilot Workspace session](https://copilot-workspace.githubnext.com/PrismarineJS/node-minecraft-protocol/issues/1362?shareId=XXXX-XXXX-XXXX-XXXX).

* add --retries 2

* lint, debug close event emit twice

* bail tests

* fix

* flaky test fix

* remove debug

* Update serverTest.js

* Fix NBT chat not being used for 1.20.3+ kicks

* Update createClient.js

* fix client.._supportFeature not being defined

* only nbt on the play state disconnect
2025-01-06 19:47:44 +01:00
..
2024-10-12 23:55:36 +02:00
2024-12-04 21:21:43 +01:00
2024-12-04 21:21:43 +01:00
2024-12-04 21:21:43 +01:00