mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-25 05:51:56 +01:00
Updated the sound system (#18724)
* sdaf * sdaf * sdfa * sadf * sfda * gfd * reduce thrusters volume * sdafsadsdaf * sdfa * Reduced some sound ranges and made some/more not ignore walls for loops * health analyzers too * ivdrip adjustment * most tools now use play_tool_sound to have the sound played, reduced range for it
This commit is contained in:
@@ -201,7 +201,7 @@
|
||||
if (2)
|
||||
if (attacking_item.isscrewdriver())
|
||||
to_chat(user, SPAN_NOTICE("You unscrew and remove the wiring cover from \the [src]."))
|
||||
playsound(loc, attacking_item.usesound, 50, 1)
|
||||
attacking_item.play_tool_sound(get_turf(src), 50)
|
||||
setconstructionstate(3)
|
||||
return TRUE
|
||||
|
||||
@@ -227,7 +227,7 @@
|
||||
|
||||
if (attacking_item.isscrewdriver())
|
||||
to_chat(user, SPAN_NOTICE("You replace and screw tight the wiring cover from \the [src]."))
|
||||
playsound(loc, attacking_item.usesound, 50, 1)
|
||||
attacking_item.play_tool_sound(get_turf(src), 50)
|
||||
setconstructionstate(2)
|
||||
return TRUE
|
||||
|
||||
|
||||
@@ -94,7 +94,7 @@ BREATH ANALYZER
|
||||
user.visible_message("<b>[user]</b> runs the scanner over the floor.", "<span class='notice'>You run the scanner over the floor.</span>", "<span class='notice'>You hear metal repeatedly clunking against the floor.</span>")
|
||||
to_chat(user, "<span class='notice'><b>Scan results for the ERROR:</b></span>")
|
||||
if(sound_scan)
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_used.ogg', 25)
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_used.ogg', 25, extrarange = SILENCED_SOUND_EXTRARANGE)
|
||||
return
|
||||
|
||||
if(!user.IsAdvancedToolUser())
|
||||
@@ -106,7 +106,7 @@ BREATH ANALYZER
|
||||
if(!istype(M, /mob/living/carbon/human))
|
||||
to_chat(user, "<span class='warning'>This scanner is designed for humanoid patients only.</span>")
|
||||
if(sound_scan)
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_used.ogg', 25)
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_used.ogg', 25, extrarange = SILENCED_SOUND_EXTRARANGE)
|
||||
return
|
||||
|
||||
var/mob/living/carbon/human/H = M
|
||||
@@ -114,7 +114,7 @@ BREATH ANALYZER
|
||||
if(H.isSynthetic() && !H.isFBP())
|
||||
to_chat(user, "<span class='warning'>This scanner is designed for organic humanoid patients only.</span>")
|
||||
if(sound_scan)
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_used.ogg', 25)
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_used.ogg', 25, extrarange = SILENCED_SOUND_EXTRARANGE)
|
||||
return
|
||||
|
||||
. = list()
|
||||
@@ -146,18 +146,18 @@ BREATH ANALYZER
|
||||
if(sound_scan)
|
||||
switch(brain_result)
|
||||
if(0)
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_dead.ogg', 25)
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_dead.ogg', 25, extrarange = SILENCED_SOUND_EXTRARANGE)
|
||||
if(-1)
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_used.ogg', 25)
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_used.ogg', 25, extrarange = SILENCED_SOUND_EXTRARANGE)
|
||||
else
|
||||
if(brain_result <= 25)
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_critical.ogg', 25)
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_critical.ogg', 25, extrarange = SHORT_RANGE_SOUND_EXTRARANGE)
|
||||
else if(brain_result <= 50)
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_danger.ogg', 25)
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_danger.ogg', 25, extrarange = SHORT_RANGE_SOUND_EXTRARANGE)
|
||||
else if(brain_result <= 90)
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_used.ogg', 25)
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_used.ogg', 25, extrarange = SILENCED_SOUND_EXTRARANGE)
|
||||
else
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_stable.ogg', 25)
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_stable.ogg', 25, extrarange = SILENCED_SOUND_EXTRARANGE)
|
||||
|
||||
// Pulse rate.
|
||||
var/pulse_result = "normal"
|
||||
@@ -635,19 +635,19 @@ BREATH ANALYZER
|
||||
|
||||
if(H.stat == DEAD || H.losebreath || !H.breathing)
|
||||
to_chat(user,"<span class='danger'>Alert: No breathing detected.</span>")
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_dead.ogg', 25)
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_dead.ogg', 25, extrarange = SILENCED_SOUND_EXTRARANGE)
|
||||
return
|
||||
|
||||
switch(H.getOxyLoss())
|
||||
if(0 to 25)
|
||||
to_chat(user,"Subject oxygen levels nominal.")
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_stable.ogg', 25)
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_stable.ogg', 25, extrarange = SILENCED_SOUND_EXTRARANGE)
|
||||
if(25 to 50)
|
||||
to_chat(user,"<span class='notice'>Subject oxygen levels abnormal.</span>")
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_danger.ogg', 25)
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_danger.ogg', 25, extrarange = SHORT_RANGE_SOUND_EXTRARANGE)
|
||||
if(50 to INFINITY)
|
||||
to_chat(user,"<span class='notice'><b>Severe oxygen deprivation detected.</b></span>")
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_critical.ogg', 25)
|
||||
playsound(user.loc, 'sound/items/healthscanner/healthscanner_critical.ogg', 25, extrarange = SHORT_RANGE_SOUND_EXTRARANGE)
|
||||
|
||||
var/obj/item/organ/internal/L = H.internal_organs_by_name[BP_LUNGS]
|
||||
if(istype(L))
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
if(attacking_item.iscrowbar())
|
||||
amount--
|
||||
to_chat(user, "<span class='notice'>You pry off the steel sheet from the [name].</span>")
|
||||
playsound(src.loc, attacking_item.usesound, 100, 1)
|
||||
attacking_item.play_tool_sound(get_turf(src), 100)
|
||||
new /obj/item/stack/material/glass/wired(user.loc)
|
||||
new /obj/item/stack/material/steel(user.loc)
|
||||
if(amount <= 0)
|
||||
|
||||
@@ -286,7 +286,7 @@
|
||||
START_PROCESSING(SSfast_process, src)
|
||||
INVOKE_ASYNC(GLOBAL_PROC, GLOBAL_PROC_REF(tgui_alert), triggerer, "You feel your [pick("right", "left")] foot step down on a button with a click..., Uh..., Oh...", "Dread", list("Mom..."))
|
||||
|
||||
playsound_allinrange(src, sound('sound/weapons/empty/empty6.ogg'))
|
||||
playsound(src, sound('sound/weapons/empty/empty6.ogg'))
|
||||
|
||||
else
|
||||
late_trigger(locate(engaged_by))
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
|
||||
/obj/item/thermal_drill/Initialize()
|
||||
. = ..()
|
||||
soundloop = new(list(src), FALSE)
|
||||
soundloop = new(src, FALSE)
|
||||
|
||||
/obj/item/thermal_drill/Destroy()
|
||||
QDEL_NULL(soundloop)
|
||||
|
||||
@@ -434,7 +434,7 @@
|
||||
)
|
||||
affecting.heal_damage(brute = 15, robo_repair = TRUE)
|
||||
user.visible_message(SPAN_WARNING("\The [user] [pick(repair_messages)] on [target]'s [affecting.name] with \the [src]."))
|
||||
playsound(target, usesound, 15)
|
||||
playsound(target, usesound, 15, extrarange = SILENCED_SOUND_EXTRARANGE)
|
||||
repair_organ(user, target, affecting)
|
||||
|
||||
/obj/item/weldingtool/afterattack(obj/O, mob/user, proximity)
|
||||
@@ -536,7 +536,7 @@
|
||||
to_chat(M, "<span class='notice'>You switch the [src] on.</span>")
|
||||
else if(T)
|
||||
T.visible_message("<span class='danger'>\The [src] turns on.</span>")
|
||||
playsound(loc, 'sound/items/welder_activate.ogg', 50, 1)
|
||||
playsound(loc, 'sound/items/welder_activate.ogg', 50, TRUE, extrarange = SILENCED_SOUND_EXTRARANGE)
|
||||
force = 22
|
||||
damtype = DAMAGE_BURN
|
||||
w_class = ITEMSIZE_LARGE
|
||||
@@ -555,7 +555,7 @@
|
||||
to_chat(M, "<span class='notice'>You switch \the [src] off.</span>")
|
||||
else if(T)
|
||||
T.visible_message("<span class='warning'>\The [src] turns off.</span>")
|
||||
playsound(loc, 'sound/items/welder_deactivate.ogg', 50, 1)
|
||||
playsound(loc, 'sound/items/welder_deactivate.ogg', 50, TRUE, extrarange = SILENCED_SOUND_EXTRARANGE)
|
||||
force = 3
|
||||
damtype = DAMAGE_BRUTE
|
||||
w_class = initial(w_class)
|
||||
@@ -826,7 +826,7 @@
|
||||
current_tool = 1
|
||||
var/tool = RADIAL_INPUT(user, tools)
|
||||
if(tool)
|
||||
playsound(user, 'sound/items/penclick.ogg', 25)
|
||||
playsound(user, 'sound/items/penclick.ogg', 25, extrarange = SILENCED_SOUND_EXTRARANGE)
|
||||
current_tool = tool
|
||||
switch(tool)
|
||||
if("wrench")
|
||||
@@ -958,7 +958,7 @@
|
||||
lit = TRUE
|
||||
if(user)
|
||||
user.visible_message(SPAN_NOTICE("[user] ignites the steel wool with \the [L]."), SPAN_NOTICE("You ignite the steel wool with \the [L]"), SPAN_NOTICE("You hear a gentle flame crackling."))
|
||||
playsound(get_turf(src), 'sound/items/flare.ogg', 50)
|
||||
playsound(get_turf(src), 'sound/items/flare.ogg', 50, extrarange = SHORT_RANGE_SOUND_EXTRARANGE)
|
||||
desc += " Watch your hands!"
|
||||
icon_state = "burning_wool"
|
||||
set_light(2, 2, LIGHT_COLOR_LAVA)
|
||||
|
||||
Reference in New Issue
Block a user