mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-10 10:08:18 +00:00
fixed header and swap sizes in datafiles (may fixes #14)
This commit is contained in:
parent
62fe7cd5b2
commit
3dd1ea0d8f
|
@ -511,7 +511,7 @@ int CDataFileWriter::Finish()
|
|||
// calculate the complete size
|
||||
TypesSize = m_NumItemTypes*sizeof(CDatafileItemType);
|
||||
HeaderSize = sizeof(CDatafileHeader);
|
||||
OffsetSize = m_NumItems*sizeof(int) + m_NumDatas*sizeof(int);
|
||||
OffsetSize = (m_NumItems + m_NumDatas + m_NumDatas) * sizeof(int); //ItemOffsets, DataOffsets, DataSizes
|
||||
FileSize = HeaderSize + TypesSize + OffsetSize + ItemSize + DataSize;
|
||||
SwapSize = FileSize - DataSize;
|
||||
|
||||
|
|
Loading…
Reference in a new issue