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);