summaryrefslogtreecommitdiffstats
path: root/src/entities
diff options
context:
space:
mode:
authorwithmorten <morten.with@gmail.com>2021-06-26 19:14:46 +0200
committerwithmorten <morten.with@gmail.com>2021-06-26 19:14:46 +0200
commitf3a931e1c99372ae4bc224ef482d4052a09580cb (patch)
tree13992380234e68b8f1a32030b4df6aa3d6ebbaca /src/entities
parentMerge pull request #1155 from leanndroguedes/master (diff)
downloadre3-f3a931e1c99372ae4bc224ef482d4052a09580cb.tar
re3-f3a931e1c99372ae4bc224ef482d4052a09580cb.tar.gz
re3-f3a931e1c99372ae4bc224ef482d4052a09580cb.tar.bz2
re3-f3a931e1c99372ae4bc224ef482d4052a09580cb.tar.lz
re3-f3a931e1c99372ae4bc224ef482d4052a09580cb.tar.xz
re3-f3a931e1c99372ae4bc224ef482d4052a09580cb.tar.zst
re3-f3a931e1c99372ae4bc224ef482d4052a09580cb.zip
Diffstat (limited to 'src/entities')
-rw-r--r--src/entities/Entity.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/entities/Entity.cpp b/src/entities/Entity.cpp
index 9d5bf73c..a7f4bd45 100644
--- a/src/entities/Entity.cpp
+++ b/src/entities/Entity.cpp
@@ -22,6 +22,7 @@
#include "MemoryHeap.h"
#include "Bones.h"
#include "Debug.h"
+#include "SaveBuf.h"
int gBuildings;
@@ -753,7 +754,8 @@ CEntity::SaveEntityFlags(uint8*& buf)
void
CEntity::LoadEntityFlags(uint8*& buf)
{
- uint32 tmp = ReadSaveBuf<uint32>(buf);
+ uint32 tmp;
+ ReadSaveBuf(&tmp, buf);
m_type = (tmp & ((BIT(3) - 1)));
m_status = ((tmp >> 3) & (BIT(5) - 1));
@@ -784,7 +786,7 @@ CEntity::LoadEntityFlags(uint8*& buf)
bZoneCulled = !!(tmp & BIT(30));
bZoneCulled2 = !!(tmp & BIT(31));
- tmp = ReadSaveBuf<uint32>(buf);
+ ReadSaveBuf(&tmp, buf);
bRemoveFromWorld = !!(tmp & BIT(0));
bHasHitWall = !!(tmp & BIT(1));