Skip to content

Commit f17c34f

Browse files
committed
Correct actors carrying gold not preserving between reading and writing, and therein between save games.
1 parent b4a9f27 commit f17c34f

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

Source/Entities/Actor.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -335,6 +335,7 @@ int Actor::ReadProperty(const std::string_view& propName, Reader& reader) {
335335
MatchProperty("StableRecoveryDelay", { reader >> m_StableRecoverDelay; });
336336
MatchProperty("CanRun", { reader >> m_CanRun; });
337337
MatchProperty("CrouchWalkSpeedMultiplier", { reader >> m_CrouchWalkSpeedMultiplier; });
338+
MatchProperty("GoldCarried", { reader >> m_GoldCarried; });
338339
MatchProperty("AimAngle", { reader >> m_AimAngle; });
339340
MatchProperty("AimRange", { reader >> m_AimRange; });
340341
MatchProperty("AimDistance", { reader >> m_AimDistance; });
@@ -413,6 +414,8 @@ int Actor::Save(Writer& writer) const {
413414
writer << m_CanRun;
414415
writer.NewProperty("CrouchWalkSpeedMultiplier");
415416
writer << m_CrouchWalkSpeedMultiplier;
417+
writer.NewProperty("GoldCarried");
418+
writer << m_GoldCarried;
416419
writer.NewProperty("AimAngle");
417420
writer << m_AimAngle;
418421
writer.NewProperty("AimRange");

0 commit comments

Comments
 (0)