From 5746f42d73118b70ceb43edc864897243c766923 Mon Sep 17 00:00:00 2001 From: Hual Date: Thu, 22 Jun 2023 13:23:17 +0300 Subject: [PATCH] Fixes --- Server/Components/Recordings/recordings_main.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Server/Components/Recordings/recordings_main.cpp b/Server/Components/Recordings/recordings_main.cpp index 3044278a0..0a884b595 100644 --- a/Server/Components/Recordings/recordings_main.cpp +++ b/Server/Components/Recordings/recordings_main.cpp @@ -98,7 +98,7 @@ class RecordingsComponent final : public IRecordingsComponent, public PlayerConn } // Write on foot recording data - if (data->type_ == PlayerRecordingType_Driver && data->file_.good()) + if (data->type_ == PlayerRecordingType_OnFoot && data->file_.good()) { const uint32_t timeSinceRecordStart = duration_cast(Time::now() - data->start_).count(); data->file_.write(reinterpret_cast(&timeSinceRecordStart), sizeof(uint32_t)); @@ -150,7 +150,7 @@ class RecordingsComponent final : public IRecordingsComponent, public PlayerConn // Write driver recording data if (data->type_ == PlayerRecordingType_Driver && data->file_.good()) { - uint32_t timeSinceRecordStart = duration_cast(Time::now() - data->start_).count(); + const uint32_t timeSinceRecordStart = duration_cast(Time::now() - data->start_).count(); data->file_.write(reinterpret_cast(&timeSinceRecordStart), sizeof(uint32_t)); uint8_t playerHealth = static_cast(vehicleSync.PlayerHealthArmour.x);