mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-07-13 09:05:11 +01:00
Merge pull request #25738 from coiax/minor-time-tweaks
Minor changes to some time procs
This commit is contained in:
@@ -1,13 +1,15 @@
|
||||
//Returns the world time in english
|
||||
/proc/worldtime2text()
|
||||
return gameTimestamp("hh:mm:ss")
|
||||
return gameTimestamp("hh:mm:ss", world.time)
|
||||
|
||||
/proc/time_stamp(format = "hh:mm:ss", show_ds)
|
||||
var/time_string = time2text(world.timeofday, format)
|
||||
return show_ds ? "[time_string]:[world.timeofday % 10]" : time_string
|
||||
|
||||
/proc/gameTimestamp(format = "hh:mm:ss") // Get the game time in text
|
||||
return time2text(world.time - timezoneOffset + 432000 - round_start_time, format)
|
||||
/proc/gameTimestamp(format = "hh:mm:ss", wtime=null)
|
||||
if(!wtime)
|
||||
wtime = world.time
|
||||
return time2text(wtime - timezoneOffset + ticker.gametime_offset - round_start_time, format)
|
||||
|
||||
/* Returns 1 if it is the selected month and day */
|
||||
/proc/isDay(month, day)
|
||||
|
||||
@@ -44,6 +44,8 @@ var/datum/controller/subsystem/ticker/ticker
|
||||
var/timeLeft //pregame timer
|
||||
var/start_at
|
||||
|
||||
var/gametime_offset = 432000 // equal to 12 hours, making gametime at roundstart 12:00:00
|
||||
|
||||
var/totalPlayers = 0 //used for pregame stats on statpanel
|
||||
var/totalPlayersReady = 0 //used for pregame stats on statpanel
|
||||
|
||||
|
||||
Reference in New Issue
Block a user