mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2026-11-06 11:57:13 +00:00
fix: name the fourth flair colour byte padding
The client never sets or reads it, so it holds leftover memory. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -69,7 +69,7 @@ NiPoint3 Chunk::GridToWorldPos(uint32_t i, uint32_t j) const {
|
||||
BinaryIO::BinaryRead(stream, flair.colorR);
|
||||
BinaryIO::BinaryRead(stream, flair.colorG);
|
||||
BinaryIO::BinaryRead(stream, flair.colorB);
|
||||
BinaryIO::BinaryRead(stream, flair.colorA);
|
||||
BinaryIO::BinaryRead(stream, flair.padding);
|
||||
return true;
|
||||
} catch (const std::exception&) {
|
||||
return false;
|
||||
|
||||
@@ -25,8 +25,10 @@ struct FlairAttributes {
|
||||
uint8_t colorR;
|
||||
uint8_t colorG;
|
||||
uint8_t colorB;
|
||||
uint8_t colorA;
|
||||
// Padding: never set when a flair is placed, so it holds leftover memory; nothing reads it
|
||||
uint8_t padding;
|
||||
};
|
||||
static_assert(sizeof(FlairAttributes) == 36, "a flair record in the .raw is 36 bytes");
|
||||
|
||||
/**
|
||||
* @brief Mesh triangle structure
|
||||
|
||||
Reference in New Issue
Block a user