mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-26 22:50:26 +01:00
Fixes lobby sound runtimes (#24351)
* Fixes lobby sound * Duh * Good suggestion
This commit is contained in:
@@ -58,13 +58,11 @@ var/datum/subsystem/ticker/ticker
|
||||
|
||||
/datum/subsystem/ticker/New()
|
||||
NEW_SS_GLOBAL(ticker)
|
||||
if(SSevent.holidays && SSevent.holidays[APRIL_FOOLS])
|
||||
login_music = 'sound/ambience/clown.ogg'
|
||||
else
|
||||
var/list/music = file2list(ROUND_START_MUSIC_LIST, "\n")
|
||||
login_music = pick(music)
|
||||
|
||||
/datum/subsystem/ticker/Initialize(timeofday)
|
||||
var/list/music = file2list(ROUND_START_MUSIC_LIST, "\n")
|
||||
login_music = pick(music)
|
||||
|
||||
if(!syndicate_code_phrase)
|
||||
syndicate_code_phrase = generate_code_phrase()
|
||||
if(!syndicate_code_response)
|
||||
|
||||
+3
-1
@@ -83,7 +83,9 @@
|
||||
src << sound(null, repeat = 0, wait = 0, volume = 85, channel = 1)
|
||||
|
||||
/client/proc/playtitlemusic()
|
||||
if(!ticker || !ticker.login_music)
|
||||
while(ticker.current_state == GAME_STATE_STARTUP) //wait for ticker init to set the login music
|
||||
stoplag()
|
||||
if(!ticker.login_music)
|
||||
return
|
||||
if(prefs && (prefs.toggles & SOUND_LOBBY))
|
||||
src << sound(ticker.login_music, repeat = 0, wait = 0, volume = 85, channel = 1) // MAD JAMS
|
||||
|
||||
@@ -141,6 +141,14 @@
|
||||
end_day = 2
|
||||
begin_month = APRIL
|
||||
|
||||
/datum/holiday/april_fools/celebrate()
|
||||
if(ticker)
|
||||
ticker.login_music = 'sound/ambience/clown.ogg'
|
||||
for(var/mob/new_player/P in mob_list)
|
||||
if(P.client)
|
||||
P.stopLobbySound()
|
||||
P.client.playtitlemusic()
|
||||
|
||||
/datum/holiday/fourtwenty
|
||||
name = "Four-Twenty"
|
||||
begin_day = 20
|
||||
|
||||
Reference in New Issue
Block a user