diff --git a/ATTRIBUTIONS.md b/ATTRIBUTIONS.md index c8e739501a..4e4af5cc4e 100644 --- a/ATTRIBUTIONS.md +++ b/ATTRIBUTIONS.md @@ -127,3 +127,7 @@ **Creator:** Commissioned by Cross_Exonar from Toriate
**Link:** https://github.com/TS-Rogue-Star/Rogue-Star/pull/1010
**License:** [CC BY-SA 3.0](https://creativecommons.org/licenses/by-sa/3.0/)
+
+**File:** `/sound/talksounds/looc_sound.ogg`
+**Creator:** VerySoft
+**License:** [CC BY-SA 3.0](https://creativecommons.org/licenses/by-sa/3.0/)
diff --git a/code/modules/client/preferences/types/game/sound.dm b/code/modules/client/preferences/types/game/sound.dm index 8c4189145e..cbd2e367da 100644 --- a/code/modules/client/preferences/types/game/sound.dm +++ b/code/modules/client/preferences/types/game/sound.dm @@ -87,6 +87,12 @@ default_value = TRUE savefile_identifier = PREFERENCE_PLAYER +/datum/preference/toggle/looc_sounds + category = PREFERENCE_CATEGORY_GAME_PREFERENCES + savefile_key = "LOOC_SOUNDS" + default_value = TRUE + savefile_identifier = PREFERENCE_PLAYER + /datum/preference/toggle/air_pump_noise category = PREFERENCE_CATEGORY_GAME_PREFERENCES savefile_key = "SOUND_AIRPUMP" diff --git a/code/modules/client/verbs/ooc.dm b/code/modules/client/verbs/ooc.dm index b65bb906cf..a65e1d29b3 100644 --- a/code/modules/client/verbs/ooc.dm +++ b/code/modules/client/verbs/ooc.dm @@ -176,6 +176,8 @@ admin_stuff += "/([key])" to_chat(target, span_looc(create_text_tag("looc", "LOOC:", target) + " [display_name][admin_stuff]: " + span_message("[msg]"))) + if(target.prefs?.read_preference(/datum/preference/toggle/looc_sounds)) + SEND_SOUND(target, sound('sound/talksounds/looc_sound.ogg', volume = 50)) //Only sound for actually local targets, not for RLOOC because that would be annoying for(var/client/target in r_receivers) var/admin_stuff = "/([key])([admin_jump_link(mob, target.holder)])" diff --git a/sound/talksounds/looc_sound.ogg b/sound/talksounds/looc_sound.ogg new file mode 100644 index 0000000000..d5380a7e60 Binary files /dev/null and b/sound/talksounds/looc_sound.ogg differ diff --git a/tgui/packages/tgui/interfaces/PreferencesMenu/preferences/features/game_preferences/sound.tsx b/tgui/packages/tgui/interfaces/PreferencesMenu/preferences/features/game_preferences/sound.tsx index 3209c1bb62..c144611b1a 100644 --- a/tgui/packages/tgui/interfaces/PreferencesMenu/preferences/features/game_preferences/sound.tsx +++ b/tgui/packages/tgui/interfaces/PreferencesMenu/preferences/features/game_preferences/sound.tsx @@ -99,6 +99,13 @@ export const SUBTLE_SOUNDS: FeatureToggle = { component: CheckboxInput, }; +export const LOOC_SOUNDS: FeatureToggle = { + name: 'LOOC Sounds', + category: 'SOUNDS', + description: 'Enable hearing a sound when somebody uses LOOC.', + component: CheckboxInput, +}; + export const SOUND_AIRPUMP: FeatureToggle = { name: 'Air Pump Ambient Noise', category: 'SOUNDS',