You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
thrownewException($"CS2 Surf ERROR >> OnPlayerConnect -> Failed to write new player to database, this shouldnt happen. Player: {name} ({player.SteamID})");
@@ -174,9 +177,11 @@ public HookResult OnPlayerDisconnect(EventPlayerDisconnect @event, GameEventInfo
174
177
else
175
178
{
176
179
// Update data in Player DB table
177
-
Task<int>updatePlayerTask=DB.Write($"UPDATE `Player` SET country = '{playerList[player.UserId??0].Profile.Country}', "+
WHERE `id` = {playerList[player.UserId??0].Profile.ID} LIMIT 1;
184
+
");
180
185
if(updatePlayerTask.Result!=1)
181
186
thrownewException($"CS2 Surf ERROR >> OnPlayerDisconnect -> Failed to update player data in database. Player: {player.PlayerName} ({player.SteamID})");
$"{player.Stats.ThisRun.StartVelX}, {player.Stats.ThisRun.StartVelY}, {player.Stats.ThisRun.StartVelZ}, {velocity_x}, {velocity_y}, {velocity_z}, {(int)DateTimeOffset.UtcNow.ToUnixTimeSeconds()}) "+// To-do: get the `start_vel` values for the run from CP implementation
thrownewException($"CS2 Surf ERROR >> internal class PersonalBest -> SaveMapTime -> Failed to insert/update player run in database. Player: {player.Profile.Name} ({player.Profile.SteamID})");
64
66
updatePlayerRunTask.Dispose();
@@ -91,30 +93,33 @@ public void SaveMapTime(Player player, TimerDatabase DB)
0 commit comments