Open ETcodehome opened 8 years ago
Yes, there is only a single sum stored, no increments. The actual code to update the info is here: https://github.com/uncovery/uncovery_me/blob/master/includes/uuid.inc.php#L58
There is no way you can add that function since the information is not there - unless you want to re-calculate it from the login-logout time stamps in the universal log.
Looking at adding a time played since
function umc_get_online_hours_since($user, $timestamp) { XMPP_ERROR_trace(FUNCTION, func_get_args()); $uuid = umc_uuid_getone($user, 'uuid'); $sql = "SELECT onlinetime FROM minecraft_srvr.UUID WHERE UUID='$uuid';"; $data = umc_mysql_fetch_all($sql); if (count($data) == 0) { return false; } $onlinetime = round($data[0]['onlinetime'] / 60 / 60); return $onlinetime; }
The issue i am running into is I have no reference for the table structure of the sql returned query.
Is there data on each login / logout event or is it just a "lump sum" value stored of time played? By my understanding of this return it does seem to be just the lump sum.
I was planning on using it down the line as part of a weighted basket for contest lot priority assignment post registration as discussed.