I’m trying to apply DescribePlayerSessions() for C++ into my project using UE4 because if a user doesn’t join a dedicated server after the user is matched by FlexMatch, status of the user’s player session is in “RESERVED” for 1 minute and a new user is unable to be matched since FlexMatch knows the user will join the dedicated server. That’s why I’m applying DescribePlayerSessions() to find player sessions which are in “RESERVED” status to terminate. For example, I set up a matchmaking rule which maximum and minimum number of players are 5. However, After all users are matched by FlexMatch, only 4 users join a dedicated server and 1 user close his/her client by Alt + F4.
Unfortunately, DescribePlayerSessions function is not on GameLiftServerSDK for UE4 but it’s on GameLiftServerSDK for C++. Anyway, after putting it into my project, I encountered that CreationTime of a player session was weird.
PlayerSession on a document of GameLift explains it in a box below.
CreationTime Time stamp indicating when this data object was created. Format is a number expressed in Unix time as milliseconds (for example "1469498468.057"). Type: Timestamp Required: No
It may seem to be as if a value of it is wrong. After the function is called, I displayed the value of CreationTime. So How can I use it? I want a reserved user to be removed with 20 secs.
2580164921 => this value is in CreationTime. It's based on milliseconds. 1557358324 => this value is correct UNIX Epoch. However, it's based on seconds but not milliseconds The value of CreationTime is much bigger than real UNIX Epoch.
Any help is appreciated.