mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2025-12-22 08:01:06 +00:00
re-adds radio sounds, properly this time (#8237)
they should have proper pauses and checks and shit, and should actually be properly balanced because I ported these from Bay
This commit is contained in:
@@ -73,8 +73,9 @@
|
||||
#define ASFX_VOX 8
|
||||
#define ASFX_DROPSOUND 16
|
||||
#define ASFX_ARCADE 32
|
||||
#define ASFX_RADIO 64
|
||||
|
||||
#define ASFX_DEFAULT (ASFX_AMBIENCE|ASFX_FOOTSTEPS|ASFX_VOTE|ASFX_VOX|ASFX_DROPSOUND|ASFX_ARCADE)
|
||||
#define ASFX_DEFAULT (ASFX_AMBIENCE|ASFX_FOOTSTEPS|ASFX_VOTE|ASFX_VOX|ASFX_DROPSOUND|ASFX_ARCADE|ASFX_RADIO)
|
||||
|
||||
// For secHUDs and medHUDs and variants. The number is the location of the image on the list hud_list of humans.
|
||||
#define HEALTH_HUD 1 // A simple line reading the pulse.
|
||||
|
||||
@@ -268,6 +268,14 @@ var/message_delay = 0 // To make sure restarting the recentmessages list is kept
|
||||
if(R.receive_range(display_freq, level) > -1)
|
||||
radios += R
|
||||
|
||||
// --- Radio sounds. ---
|
||||
|
||||
for(var/obj/item/device/radio/R in radios)
|
||||
if((R.last_radio_sound + 1 SECOND) < world.time && R != radio)
|
||||
playsound(R.loc, 'sound/effects/radio_chatter.ogg', 2.5, 0, -6, required_asfx_toggles = ASFX_RADIO)
|
||||
R.last_radio_sound = world.time
|
||||
|
||||
|
||||
// Get a list of mobs who can hear from the radios we collected.
|
||||
var/list/receive = get_mobs_in_radio_ranges(radios)
|
||||
|
||||
|
||||
@@ -52,6 +52,7 @@ var/global/list/default_medbay_channels = list(
|
||||
|
||||
|
||||
var/obj/item/cell/cell = /obj/item/cell/device
|
||||
var/last_radio_sound = -INFINITY
|
||||
|
||||
/obj/item/device/radio
|
||||
var/datum/radio_frequency/radio_connection
|
||||
@@ -312,6 +313,9 @@ var/global/list/default_medbay_channels = list(
|
||||
if(!radio_connection)
|
||||
set_frequency(frequency)
|
||||
|
||||
if(loc == M)
|
||||
playsound(loc, 'sound/effects/walkietalkie.ogg', 5, 0, -1, required_asfx_toggles = ASFX_RADIO)
|
||||
|
||||
/* Quick introduction:
|
||||
This new radio system uses a very robust FTL signaling technology unoriginally
|
||||
dubbed "subspace" which is somewhat similar to 'blue-space' but can't
|
||||
|
||||
@@ -4,7 +4,8 @@
|
||||
/client/proc/Toggle_asfx_vote,
|
||||
/client/proc/toggle_vox_voice,
|
||||
/client/proc/Toggle_dropsounds,
|
||||
/client/proc/Toggle_arcadesounds
|
||||
/client/proc/Toggle_arcadesounds,
|
||||
/client/proc/Toggle_radiosounds
|
||||
)
|
||||
|
||||
/client/verb/asf_toggle()
|
||||
@@ -86,4 +87,16 @@
|
||||
if(prefs.asfx_togs & ASFX_ARCADE)
|
||||
to_chat(src, "You will now hear arcade sounds.")
|
||||
else
|
||||
to_chat(src, "<font color='red'>You will no longer hear arcade sounds.</font>")
|
||||
to_chat(src, "<font color='red'>You will no longer hear arcade sounds.</font>")
|
||||
|
||||
/client/proc/Toggle_radiosounds()
|
||||
set name = "Toggle Radio SFX"
|
||||
set category = "SoundFx Prefs"
|
||||
set desc = "Toggles hearing noises made by radios."
|
||||
|
||||
prefs.asfx_togs ^= ASFX_RADIO
|
||||
prefs.save_preferences()
|
||||
if(prefs.asfx_togs & ASFX_RADIO)
|
||||
to_chat(src, "You will now hear radio sounds.")
|
||||
else
|
||||
to_chat(src, "<font color='red'>You will no longer hear radio sounds.</font>")
|
||||
Reference in New Issue
Block a user