- Added custom command to menu
- Better ungag/unmute/unsilence handling
- Fixed css_psay from console
This commit is contained in:
Dawid Bepierszcz
2024-03-02 22:16:38 +01:00
parent 7d5166cf4b
commit da6fb2fc22
8 changed files with 87 additions and 53 deletions

View File

@@ -37,7 +37,7 @@ public class PlayerPenaltyManager
{
//Console.WriteLine($"Found penalties for player with slot {slot} and penalty type {penaltyType}");
DateTime now = DateTime.Now;
DateTime now = DateTime.UtcNow;
// Check if any active penalties exist
foreach (var penalty in penaltiesList.ToList())
@@ -115,7 +115,7 @@ public class PlayerPenaltyManager
// Remove all expired penalties for all players and penalty types
public void RemoveExpiredPenalties()
{
DateTime now = DateTime.Now;
DateTime now = DateTime.UtcNow;
foreach (var kvp in penalties.ToList()) // Use ToList to avoid modification while iterating
{
var playerSlot = kvp.Key;