From 84c9484e55874c57c1c017cb2394e0c6b2f32303 Mon Sep 17 00:00:00 2001 From: Sergeanur Date: Tue, 5 May 2020 04:45:18 +0300 Subject: SetPosition, final part --- src/save/GenericGameStorage.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/save') diff --git a/src/save/GenericGameStorage.cpp b/src/save/GenericGameStorage.cpp index df34b3b5..bb074042 100644 --- a/src/save/GenericGameStorage.cpp +++ b/src/save/GenericGameStorage.cpp @@ -255,9 +255,9 @@ GenericLoad() buf = (work_buff + 0x40); ReadDataFromBufferPointer(buf, saveSize); ReadDataFromBufferPointer(buf, CGame::currLevel); - ReadDataFromBufferPointer(buf, TheCamera.GetPosition().x); - ReadDataFromBufferPointer(buf, TheCamera.GetPosition().y); - ReadDataFromBufferPointer(buf, TheCamera.GetPosition().z); + ReadDataFromBufferPointer(buf, TheCamera.GetMatrix().GetPosition().x); + ReadDataFromBufferPointer(buf, TheCamera.GetMatrix().GetPosition().y); + ReadDataFromBufferPointer(buf, TheCamera.GetMatrix().GetPosition().z); ReadDataFromBufferPointer(buf, CClock::ms_nMillisecondsPerGameMinute); ReadDataFromBufferPointer(buf, CClock::ms_nLastClockTick); ReadDataFromBufferPointer(buf, CClock::ms_nGameClockHours); @@ -538,9 +538,9 @@ RestoreForStartLoad() } else { uint8 *_buf = buf + sizeof(int32) + sizeof(wchar[24]) + sizeof(SYSTEMTIME) + sizeof(SIZE_OF_ONE_GAME_IN_BYTES); ReadDataFromBufferPointer(_buf, CGame::currLevel); - ReadDataFromBufferPointer(_buf, TheCamera.GetPosition().x); - ReadDataFromBufferPointer(_buf, TheCamera.GetPosition().y); - ReadDataFromBufferPointer(_buf, TheCamera.GetPosition().z); + ReadDataFromBufferPointer(_buf, TheCamera.GetMatrix().GetPosition().x); + ReadDataFromBufferPointer(_buf, TheCamera.GetMatrix().GetPosition().y); + ReadDataFromBufferPointer(_buf, TheCamera.GetMatrix().GetPosition().z); CStreaming::RemoveUnusedBigBuildings(CGame::currLevel); CStreaming::RemoveUnusedBuildings(CGame::currLevel); CCollision::SortOutCollisionAfterLoad(); -- cgit v1.2.3