mirror of
https://github.com/Yawn-Wider/YWPolarisVore.git
synced 2026-08-24 13:37:16 +01:00
Merge branch 'release' of https://github.com/VOREStation/VOREStation into izac
This commit is contained in:
@@ -360,14 +360,16 @@
|
||||
log_admin("Couldn't perform IP check on [key] with [address]")
|
||||
|
||||
// VOREStation Edit Start - Department Hours
|
||||
if(config.time_off)
|
||||
var/DBQuery/query_hours = dbcon.NewQuery("SELECT department, hours, total_hours FROM vr_player_hours WHERE ckey = '[sql_ckey]'")
|
||||
query_hours.Execute()
|
||||
LAZYINITLIST(department_hours)
|
||||
LAZYINITLIST(play_hours)
|
||||
var/DBQuery/query_hours = dbcon.NewQuery("SELECT department, hours, total_hours FROM vr_player_hours WHERE ckey = '[sql_ckey]'")
|
||||
if(query_hours.Execute())
|
||||
while(query_hours.NextRow())
|
||||
department_hours[query_hours.item[1]] = text2num(query_hours.item[2])
|
||||
play_hours[query_hours.item[1]] = text2num(query_hours.item[3])
|
||||
else
|
||||
var/error_message = query_hours.ErrorMsg() // Need this out here since the spawn below will split the stack and who knows what'll happen by the time it runs
|
||||
log_debug("Error loading play hours for [ckey]: [error_message]")
|
||||
spawn(0)
|
||||
alert(src, "The query to load your existing playtime failed. Screenshot this, give the screenshot to a developer, and reconnect, otherwise you may lose any recorded play hours (which may limit access to jobs). ERROR: [error_message]", "PROBLEMS!!")
|
||||
// VOREStation Edit End - Department Hours
|
||||
|
||||
if(sql_id)
|
||||
|
||||
Reference in New Issue
Block a user