diff --git a/code/game/sound.dm b/code/game/sound.dm index db2ee47365..3b37f0c8eb 100644 --- a/code/game/sound.dm +++ b/code/game/sound.dm @@ -402,7 +402,9 @@ var/list/species_sound_map = list( * get_species_sound(H.species.species_sounds_male)["emote"] // If we're male, and want an emote sound gendered correctly. */ /proc/get_species_sound(var/sounds) - return species_sound_map[sounds] + if(!islist(species_sound_map[sounds])) // We check here if this list actually has anything in it, or if we're about to return a null index + return null // Shitty failsafe but better than rewriting an entire litany of procs rn when I'm low on time - Rykka // list('modular_chomp/sound/voice/silence.ogg') + return species_sound_map[sounds] // Otherwise, successfully return our sound /* * The following helper proc will select a species' default sounds - useful for if we're set to "Unset" diff --git a/code/modules/emotes/definitions/audible_cough.dm b/code/modules/emotes/definitions/audible_cough.dm index e30b0be3fd..45323390eb 100644 --- a/code/modules/emotes/definitions/audible_cough.dm +++ b/code/modules/emotes/definitions/audible_cough.dm @@ -19,8 +19,14 @@ if(ishuman(user) && !check_synthetic(user)) var/mob/living/carbon/human/H = user var/vol = H.species.cough_volume + var/s = get_species_sound(get_gendered_sound(H))["cough"] + if(!s && !(get_species_sound(H.species.species_sounds) == "None")) // Failsafe, so we always use the default cough/etc sounds. None will cancel out anyways. + if(H.identifying_gender == FEMALE) + s = get_species_sound("Human Female")["cough"] + else // Update this if we ever get herm/etc sounds. + s = get_species_sound("Human Male")["cough"] return list( - "sound" = get_species_sound(get_gendered_sound(H))["cough"], + "sound" = s, "vol" = vol, "volchannel" = VOLUME_CHANNEL_SPECIES_SOUNDS ) diff --git a/code/modules/emotes/definitions/audible_sneeze.dm b/code/modules/emotes/definitions/audible_sneeze.dm index 3d745fa1b7..b3a0a2ba16 100644 --- a/code/modules/emotes/definitions/audible_sneeze.dm +++ b/code/modules/emotes/definitions/audible_sneeze.dm @@ -12,8 +12,14 @@ var/mob/living/carbon/human/H = user // CHOMPEdit Start: Standardize Species Sounds var/vol = H.species.sneeze_volume + var/s = get_species_sound(get_gendered_sound(H))["sneeze"] + if(!s && !(get_species_sound(H.species.species_sounds) == "None")) // Failsafe, so we always use the default sneeze/etc sounds. None will cancel out anyways. + if(H.identifying_gender == FEMALE) + s = get_species_sound("Human Female")["sneeze"] + else // Update this if we ever get herm/etc sounds. + s = get_species_sound("Human Male")["sneeze"] return list( - "sound" = get_species_sound(get_gendered_sound(H))["sneeze"], + "sound" = s, "vol" = vol, "exr" = 20, "volchannel" = VOLUME_CHANNEL_SPECIES_SOUNDS diff --git a/code/modules/mob/living/death.dm b/code/modules/mob/living/death.dm index 722062803c..90c0b8f42b 100644 --- a/code/modules/mob/living/death.dm +++ b/code/modules/mob/living/death.dm @@ -31,7 +31,8 @@ if(src.death_sound_override) // Do we override the death sounds from our species list - used by only a few specific mobs. If we do, do the next one instead playsound(src, death_sound_override, 50, 1, 20, volume_channel = VOLUME_CHANNEL_SPECIES_SOUNDS) else - playsound(src, pick(get_species_sound(get_gendered_sound(src))["death"]), 50, 1, 20, volume_channel = VOLUME_CHANNEL_SPECIES_SOUNDS) + if(!ishuman(src)) // Safety, we're not going to double up on death noises if we're not human. + playsound(src, pick(get_species_sound(get_gendered_sound(src))["death"]), 50, 1, 20, volume_channel = VOLUME_CHANNEL_SPECIES_SOUNDS) // CHOMPStation Add End . = ..() diff --git a/modular_chomp/code/modules/emotes/definitions/audiable.dm b/modular_chomp/code/modules/emotes/definitions/audiable.dm index b01c5c2f37..72273a8664 100644 --- a/modular_chomp/code/modules/emotes/definitions/audiable.dm +++ b/modular_chomp/code/modules/emotes/definitions/audiable.dm @@ -14,8 +14,14 @@ var/mob/living/carbon/human/H = user // CHOMPEdit: Standardize Species Sounds Getters var/vol = H.species.gasp_volume + var/s = get_species_sound(get_gendered_sound(H))["gasp"] + if(!s && !(get_species_sound(H.species.species_sounds) == "None")) // Failsafe, so we always use the default gasp/etc sounds. None will cancel out anyways. + if(H.identifying_gender == FEMALE) + s = get_species_sound("Human Female")["gasp"] + else // Update this if we ever get herm/etc sounds. + s = get_species_sound("Human Male")["gasp"] return list( - "sound" = get_species_sound(get_gendered_sound(H))["gasp"], + "sound" = s, "vol" = vol, "volchannel" = VOLUME_CHANNEL_SPECIES_SOUNDS ) diff --git a/modular_chomp/sound/voice/silence.ogg b/modular_chomp/sound/voice/silence.ogg new file mode 100644 index 0000000000..41ee44cd04 Binary files /dev/null and b/modular_chomp/sound/voice/silence.ogg differ