mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2026-10-02 10:53:44 +00:00
THIS CHANGES THE BYTES SENT TO THE CLIENT (intentionally). UnSmash::Serialize wrote the "duration != 3.0f" flag but guarded the value with "builderID != 3.0f" (a typo), so the 32-bit duration was always written, even after a 0 flag. The LEGO Universe 1.10.64 client (GameMessage::UnSmash::Serialize/Deserialize @ 00dc0e80/00dc0f50, default 3.0f @ 017e66b4) writes it only when duration != 3.0f. The client read the flag and ignored the trailing 32 bits, so this removes 4 junk bytes from default UnSmash messages; messages with a non-default duration are unchanged. Uses WriteOptional/ReadOptional and adds Deserialize. Verified with hand computed golden bits for every flag combination and round trips. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>