Hello everyone, I came across a problem with getting the time in seconds of a player, the essence:
This used to work correctly
TimeSpan.FromSeconds(player.Connection.GetSecondsConnected());
It getting the player time from the moment he connected to the server 00:00:00 and counter was increment.
But recently, I noticed that this counter began to display the original value with a minus of -00:50:00 and count it -00:49:59 and so on.
I tried to change this time in such a way:
private void OnPlayerInit(BasePlayer player)
{
player.Connection.connectionTime = (double)0.0d;
}But it did not give me a result. This method removes the player’s counter with a minus, but does not assign 0 but makes huge numbers, about 60,000 seconds.
Sorry for my bad English, I tried to clearly explain the problem.