diff --git a/code/datums/ai/basic_mobs/basic_subtrees/speech_subtree.dm b/code/datums/ai/basic_mobs/basic_subtrees/speech_subtree.dm index 8340d1da4d3..e040a566bcf 100644 --- a/code/datums/ai/basic_mobs/basic_subtrees/speech_subtree.dm +++ b/code/datums/ai/basic_mobs/basic_subtrees/speech_subtree.dm @@ -31,15 +31,19 @@ var/random_number_in_range = rand(1, total_choices_length) + // Sound that plays when the mob does something audible + var/sound_to_play = length(sound) > 0 ? pick(sound) : null + if(random_number_in_range <= audible_emotes_length) - controller.queue_behavior(/datum/ai_behavior/perform_emote, pick(emote_hear)) + controller.queue_behavior(/datum/ai_behavior/perform_emote, pick(emote_hear), sound_to_play) else if(random_number_in_range <= (audible_emotes_length + non_audible_emotes_length)) controller.queue_behavior(/datum/ai_behavior/perform_emote, pick(emote_see)) else - controller.queue_behavior(/datum/ai_behavior/perform_speech, pick(speak), length(sound) > 0 ? pick(sound) : null) + controller.queue_behavior(/datum/ai_behavior/perform_speech, pick(speak), sound_to_play) /datum/ai_planning_subtree/random_speech/insect speech_chance = 5 + sound = list('sound/creatures/chitter.ogg') emote_hear = list("chitters.") /datum/ai_planning_subtree/random_speech/mothroach @@ -49,6 +53,7 @@ /datum/ai_planning_subtree/random_speech/mouse speech_chance = 1 speak = list("Squeak!", "SQUEAK!", "Squeak?") + sound = list('sound/creatures/mousesqueek.ogg') emote_hear = list("squeaks.") emote_see = list("runs in a circle.", "shakes.") @@ -93,12 +98,14 @@ /datum/ai_planning_subtree/random_speech/chicken speech_chance = 15 // really talkative ladies speak = list("Cluck!", "BWAAAAARK BWAK BWAK BWAK!", "Bwaak bwak.") + sound = list('sound/creatures/clucks.ogg', 'sound/creatures/bagawk.ogg') emote_hear = list("clucks.", "croons.") emote_see = list("pecks at the ground.","flaps her wings viciously.") /datum/ai_planning_subtree/random_speech/chick speech_chance = 4 speak = list("Cherp.", "Cherp?", "Chirrup.", "Cheep!") + sound = list('sound/creatures/chick_peep.ogg') emote_hear = list("cheeps.") emote_see = list("pecks at the ground.","flaps her tiny wings.") @@ -160,33 +167,37 @@ /datum/ai_planning_subtree/random_speech/pony speech_chance = 3 + sound = list('sound/creatures/pony/whinny01.ogg', 'sound/creatures/pony/whinny02.ogg', 'sound/creatures/pony/whinny03.ogg') emote_hear = list("whinnies!") emote_see = list("horses around.") /datum/ai_planning_subtree/random_speech/pony/tamed speech_chance = 3 + sound = list('sound/creatures/pony/snort.ogg') + emote_hear = list("snorts.") emote_see = list("snorts.") /datum/ai_planning_subtree/random_speech/killer_tomato speech_chance = 3 - speak = list("gnashes.", "growls lowly.", "snarls.") - emote_hear = list("gnashes.") + emote_hear = list("gnashes.", "growls lowly.", "snarls.") emote_see = list("salivates.") /datum/ai_planning_subtree/random_speech/ant speech_chance = 1 + speak = list("BZZZZT!", "CHTCHTCHT!", "Bzzz", "ChtChtCht") + sound = list('sound/creatures/chitter.ogg') emote_hear = list("buzzes.", "clacks.") emote_see = list("shakes their head.", "twitches their antennae.") - speak = list("BZZZZT!", "CHTCHTCHT!", "Bzzz", "ChtChtCht") /datum/ai_planning_subtree/random_speech/fox speech_chance = 1 + speak = list("Ack-Ack", "Ack-Ack-Ack-Ackawoooo", "Geckers", "Awoo", "Tchoff") emote_hear = list("howls.", "barks.", "screams.") emote_see = list("shakes their head.", "shivers.") - speak = list("Ack-Ack", "Ack-Ack-Ack-Ackawoooo", "Geckers", "Awoo", "Tchoff") /datum/ai_planning_subtree/random_speech/crab speech_chance = 1 + sound = list('sound/creatures/claw_click.ogg') emote_hear = list("clicks.") emote_see = list("clacks.") diff --git a/code/datums/ai/generic/generic_behaviors.dm b/code/datums/ai/generic/generic_behaviors.dm index e7bfe7a7c60..fd6d848f2d6 100644 --- a/code/datums/ai/generic/generic_behaviors.dm +++ b/code/datums/ai/generic/generic_behaviors.dm @@ -287,11 +287,13 @@ /datum/ai_behavior/perform_emote -/datum/ai_behavior/perform_emote/perform(seconds_per_tick, datum/ai_controller/controller, emote) +/datum/ai_behavior/perform_emote/perform(seconds_per_tick, datum/ai_controller/controller, emote, speech_sound) var/mob/living/living_pawn = controller.pawn if(!istype(living_pawn)) return living_pawn.manual_emote(emote) + if(speech_sound) // Only audible emotes will pass in a sound + playsound(living_pawn, speech_sound, 80, vary = TRUE) finish_action(controller, TRUE) /datum/ai_behavior/perform_speech diff --git a/code/game/machinery/dna_infuser/organ_sets/rat_organs.dm b/code/game/machinery/dna_infuser/organ_sets/rat_organs.dm index 57067db47f6..96c33871a40 100644 --- a/code/game/machinery/dna_infuser/organ_sets/rat_organs.dm +++ b/code/game/machinery/dna_infuser/organ_sets/rat_organs.dm @@ -133,7 +133,7 @@ . = ..() if(prob(5)) owner.emote("squeaks") - playsound(owner, 'sound/effects/mousesqueek.ogg', 100) + playsound(owner, 'sound/creatures/mousesqueek.ogg', 100) #undef RAT_ORGAN_COLOR #undef RAT_SCLERA_COLOR diff --git a/code/modules/events/mice_migration.dm b/code/modules/events/mice_migration.dm index e7f31567f4c..450f9100800 100644 --- a/code/modules/events/mice_migration.dm +++ b/code/modules/events/mice_migration.dm @@ -23,7 +23,7 @@ priority_announce("Due to [cause], [plural] [name] have [movement] \ into the [location].", "Migration Alert", - 'sound/effects/mousesqueek.ogg') + 'sound/creatures/mousesqueek.ogg') /datum/round_event/mice_migration/start() SSminor_mapping.trigger_migration(rand(minimum_mice, maximum_mice)) diff --git a/code/modules/mob/living/basic/vermin/mouse.dm b/code/modules/mob/living/basic/vermin/mouse.dm index 0b3645b3e0f..9e8f1b8df55 100644 --- a/code/modules/mob/living/basic/vermin/mouse.dm +++ b/code/modules/mob/living/basic/vermin/mouse.dm @@ -51,7 +51,7 @@ held_state = "mouse_[body_color]" // not handled by variety element AddElement(/datum/element/animal_variety, "mouse", body_color, FALSE) AddElement(/datum/element/swabable, CELL_LINE_TABLE_MOUSE, CELL_VIRUS_TABLE_GENERIC_MOB, 1, 10) - AddComponent(/datum/component/squeak, list('sound/effects/mousesqueek.ogg' = 1), 100, extrarange = SHORT_RANGE_SOUND_EXTRARANGE) //as quiet as a mouse or whatever + AddComponent(/datum/component/squeak, list('sound/creatures/mousesqueek.ogg' = 1), 100, extrarange = SHORT_RANGE_SOUND_EXTRARANGE) //as quiet as a mouse or whatever var/static/list/loc_connections = list( COMSIG_ATOM_ENTERED = PROC_REF(on_entered), ) diff --git a/sound/creatures/bagawk.ogg b/sound/creatures/bagawk.ogg new file mode 100644 index 00000000000..bfdce2da489 Binary files /dev/null and b/sound/creatures/bagawk.ogg differ diff --git a/sound/creatures/chick_peep.ogg b/sound/creatures/chick_peep.ogg new file mode 100644 index 00000000000..1e84d1d765f Binary files /dev/null and b/sound/creatures/chick_peep.ogg differ diff --git a/sound/creatures/chitter.ogg b/sound/creatures/chitter.ogg new file mode 100644 index 00000000000..5b2a1443886 Binary files /dev/null and b/sound/creatures/chitter.ogg differ diff --git a/sound/creatures/claw_click.ogg b/sound/creatures/claw_click.ogg new file mode 100644 index 00000000000..965b4c3fa9f Binary files /dev/null and b/sound/creatures/claw_click.ogg differ diff --git a/sound/creatures/clucks.ogg b/sound/creatures/clucks.ogg new file mode 100644 index 00000000000..176f46f866f Binary files /dev/null and b/sound/creatures/clucks.ogg differ diff --git a/sound/effects/mousesqueek.ogg b/sound/creatures/mousesqueek.ogg similarity index 100% rename from sound/effects/mousesqueek.ogg rename to sound/creatures/mousesqueek.ogg diff --git a/sound/creatures/pony/snort.ogg b/sound/creatures/pony/snort.ogg index b023ddcf47c..0ea56ad957d 100644 Binary files a/sound/creatures/pony/snort.ogg and b/sound/creatures/pony/snort.ogg differ