Merge remote-tracking branch 'upstream/master' into dev-freeze

Conflicts:
	code/setup.dm
This commit is contained in:
PsiOmegaDelta
2015-08-17 09:37:49 +02:00
31 changed files with 327 additions and 288 deletions

View File

@@ -12,7 +12,7 @@ proc/worldtime2text(time = world.time)
proc/worlddate2text()
return num2text((text2num(time2text(world.timeofday, "YYYY"))+544)) + "-" + time2text(world.timeofday, "MM-DD")
proc/time_stamp()
return time2text(world.timeofday, "hh:mm:ss")
@@ -27,3 +27,18 @@ proc/isDay(var/month, var/day)
// Uncomment this out when debugging!
//else
//return 1
var/next_duration_update = 0
var/last_round_duration = 0
proc/round_duration()
if(last_round_duration && world.time < next_duration_update)
return last_round_duration
var/mills = world.time // 1/10 of a second, not real milliseconds but whatever
//var/secs = ((mills % 36000) % 600) / 10 //Not really needed, but I'll leave it here for refrence.. or something
var/mins = (mills % 36000) / 600
var/hours = mills / 36000
last_round_duration = "[round(hours)]h [round(mins)]m"
next_duration_update = world.time + 1 MINUTES
return last_round_duration