Isle
Loading...
Searching...
No Matches
mxdschunk.cpp
Go to the documentation of this file.
1#include "mxdschunk.h"
2
4
5// FUNCTION: LEGO1 0x100be050
6// FUNCTION: BETA10 0x10147290
8{
9 m_data = NULL;
10 m_flags = 0;
11 m_objectId = -1;
12 m_time = 0;
13 m_length = 0;
14}
15
16// FUNCTION: LEGO1 0x100be170
17// FUNCTION: BETA10 0x10147330
19{
20 if (m_flags & DS_CHUNK_BIT1) {
21 delete[] m_data;
22 }
23}
24
25// FUNCTION: LEGO1 0x100be1e0
26// FUNCTION: BETA10 0x101473c5
28{
29 return 0x0e;
30}
[AI] Represents a chunk of data extracted from a stream (typically from a Mindscape/Mx SI file or str...
Definition: mxdschunk.h:38
static MxU32 GetHeaderSize()
[AI] Returns the fixed size of the chunk header, typically used for parsing binary streams.
Definition: mxdschunk.cpp:27
MxLong m_time
[AI] Timestamp (tick/frame) value for the chunk. Used for ordering, sequencing, and synchronization....
Definition: mxdschunk.h:125
MxU32 m_objectId
[AI] Logical id field linking chunk to a resource, action, or entity. [AI]
Definition: mxdschunk.h:124
~MxDSChunk() override
[AI] Virtual destructor. Cleans up any owned chunk data if flagged by DS_CHUNK_BIT1....
Definition: mxdschunk.cpp:18
MxU16 m_flags
[AI] Flag bitfield indicating properties/status of the chunk. See DS_CHUNK_* defines....
Definition: mxdschunk.h:123
MxU32 m_length
[AI] Number of bytes of data in this chunk's payload. [AI]
Definition: mxdschunk.h:126
MxDSChunk()
[AI] Constructs a new, empty chunk. All members initialized to safe defaults. [AI]
Definition: mxdschunk.cpp:7
MxU8 * m_data
[AI] Pointer to chunk's raw data buffer. Ownership is determined by DS_CHUNK_BIT1 flag and usage cont...
Definition: mxdschunk.h:127
#define DECOMP_SIZE_ASSERT(T, S)
Definition: decomp.h:19
#define NULL
[AI] Null pointer value (C/C++ semantics).
Definition: legotypes.h:26
#define DS_CHUNK_BIT1
[AI] Flag bit indicating that the data should be released (freed) when the chunk is destroyed.
Definition: mxdschunk.h:10
unsigned int MxU32
[AI]
Definition: mxtypes.h:32