From fbec5d18cf175d9418fed77fcb38b673692771c6 Mon Sep 17 00:00:00 2001 From: "ilya.mikheev.coder" Date: Sun, 14 Apr 2024 15:33:04 +0200 Subject: [PATCH] Use round time instead of server time for criminal history (#26949) make criminal records computer use round time for history instead of the server time --- .../CriminalRecords/Systems/CriminalRecordsSystem.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Content.Server/CriminalRecords/Systems/CriminalRecordsSystem.cs b/Content.Server/CriminalRecords/Systems/CriminalRecordsSystem.cs index efec18485c..9ffe944486 100644 --- a/Content.Server/CriminalRecords/Systems/CriminalRecordsSystem.cs +++ b/Content.Server/CriminalRecords/Systems/CriminalRecordsSystem.cs @@ -3,7 +3,7 @@ using Content.Server.StationRecords.Systems; using Content.Shared.CriminalRecords; using Content.Shared.Security; using Content.Shared.StationRecords; -using Robust.Shared.Timing; +using Content.Server.GameTicking; namespace Content.Server.CriminalRecords.Systems; @@ -17,7 +17,7 @@ namespace Content.Server.CriminalRecords.Systems; /// public sealed class CriminalRecordsSystem : EntitySystem { - [Dependency] private readonly IGameTiming _timing = default!; + [Dependency] private readonly GameTicker _ticker = default!; [Dependency] private readonly StationRecordsSystem _stationRecords = default!; public override void Initialize() @@ -71,7 +71,7 @@ public sealed class CriminalRecordsSystem : EntitySystem /// public bool TryAddHistory(StationRecordKey key, string line) { - var entry = new CrimeHistory(_timing.CurTime, line); + var entry = new CrimeHistory(_ticker.RoundDuration(), line); return TryAddHistory(key, entry); } -- 2.51.2