mirror of
https://github.com/Yawn-Wider/YWPolarisVore.git
synced 2026-08-25 14:07:18 +01:00
Revert "Merge pull request #16240 from ShadowLarkens/revert"
This reverts commit885171f985, reversing changes made to3e314f8064.
This commit is contained in:
@@ -2,41 +2,41 @@
|
||||
name = "UI"
|
||||
sort_order = 1
|
||||
|
||||
/datum/category_item/player_setup_item/player_global/ui/load_preferences(var/savefile/S)
|
||||
S["UI_style"] >> pref.UI_style
|
||||
S["UI_style_color"] >> pref.UI_style_color
|
||||
S["UI_style_alpha"] >> pref.UI_style_alpha
|
||||
S["ooccolor"] >> pref.ooccolor
|
||||
S["tooltipstyle"] >> pref.tooltipstyle
|
||||
S["client_fps"] >> pref.client_fps
|
||||
S["ambience_freq"] >> pref.ambience_freq
|
||||
S["ambience_chance"] >> pref.ambience_chance
|
||||
S["tgui_fancy"] >> pref.tgui_fancy
|
||||
S["tgui_lock"] >> pref.tgui_lock
|
||||
S["tgui_input_mode"] >> pref.tgui_input_mode
|
||||
S["tgui_large_buttons"] >> pref.tgui_large_buttons
|
||||
S["tgui_swapped_buttons"] >> pref.tgui_swapped_buttons
|
||||
S["obfuscate_key"] >> pref.obfuscate_key
|
||||
S["obfuscate_job"] >> pref.obfuscate_job
|
||||
S["chat_timestamp"] >> pref.chat_timestamp
|
||||
/datum/category_item/player_setup_item/player_global/ui/load_preferences(datum/json_savefile/savefile)
|
||||
pref.UI_style = savefile.get_entry("UI_style")
|
||||
pref.UI_style_color = savefile.get_entry("UI_style_color")
|
||||
pref.UI_style_alpha = savefile.get_entry("UI_style_alpha")
|
||||
pref.ooccolor = savefile.get_entry("ooccolor")
|
||||
pref.tooltipstyle = savefile.get_entry("tooltipstyle")
|
||||
pref.client_fps = savefile.get_entry("client_fps")
|
||||
pref.ambience_freq = savefile.get_entry("ambience_freq")
|
||||
pref.ambience_chance = savefile.get_entry("ambience_chance")
|
||||
pref.tgui_fancy = savefile.get_entry("tgui_fancy")
|
||||
pref.tgui_lock = savefile.get_entry("tgui_lock")
|
||||
pref.tgui_input_mode = savefile.get_entry("tgui_input_mode")
|
||||
pref.tgui_large_buttons = savefile.get_entry("tgui_large_buttons")
|
||||
pref.tgui_swapped_buttons = savefile.get_entry("tgui_swapped_buttons")
|
||||
pref.obfuscate_key = savefile.get_entry("obfuscate_key")
|
||||
pref.obfuscate_job = savefile.get_entry("obfuscate_job")
|
||||
pref.chat_timestamp = savefile.get_entry("chat_timestamp")
|
||||
|
||||
/datum/category_item/player_setup_item/player_global/ui/save_preferences(var/savefile/S)
|
||||
S["UI_style"] << pref.UI_style
|
||||
S["UI_style_color"] << pref.UI_style_color
|
||||
S["UI_style_alpha"] << pref.UI_style_alpha
|
||||
S["ooccolor"] << pref.ooccolor
|
||||
S["tooltipstyle"] << pref.tooltipstyle
|
||||
S["client_fps"] << pref.client_fps
|
||||
S["ambience_freq"] << pref.ambience_freq
|
||||
S["ambience_chance"] << pref.ambience_chance
|
||||
S["tgui_fancy"] << pref.tgui_fancy
|
||||
S["tgui_lock"] << pref.tgui_lock
|
||||
S["tgui_input_mode"] << pref.tgui_input_mode
|
||||
S["tgui_large_buttons"] << pref.tgui_large_buttons
|
||||
S["tgui_swapped_buttons"] << pref.tgui_swapped_buttons
|
||||
S["obfuscate_key"] << pref.obfuscate_key
|
||||
S["obfuscate_job"] << pref.obfuscate_job
|
||||
S["chat_timestamp"] << pref.chat_timestamp
|
||||
/datum/category_item/player_setup_item/player_global/ui/save_preferences(datum/json_savefile/savefile)
|
||||
savefile.set_entry("UI_style", pref.UI_style)
|
||||
savefile.set_entry("UI_style_color", pref.UI_style_color)
|
||||
savefile.set_entry("UI_style_alpha", pref.UI_style_alpha)
|
||||
savefile.set_entry("ooccolor", pref.ooccolor)
|
||||
savefile.set_entry("tooltipstyle", pref.tooltipstyle)
|
||||
savefile.set_entry("client_fps", pref.client_fps)
|
||||
savefile.set_entry("ambience_freq", pref.ambience_freq)
|
||||
savefile.set_entry("ambience_chance", pref.ambience_chance)
|
||||
savefile.set_entry("tgui_fancy", pref.tgui_fancy)
|
||||
savefile.set_entry("tgui_lock", pref.tgui_lock)
|
||||
savefile.set_entry("tgui_input_mode", pref.tgui_input_mode)
|
||||
savefile.set_entry("tgui_large_buttons", pref.tgui_large_buttons)
|
||||
savefile.set_entry("tgui_swapped_buttons", pref.tgui_swapped_buttons)
|
||||
savefile.set_entry("obfuscate_key", pref.obfuscate_key)
|
||||
savefile.set_entry("obfuscate_job", pref.obfuscate_job)
|
||||
savefile.set_entry("chat_timestamp", pref.chat_timestamp)
|
||||
|
||||
/datum/category_item/player_setup_item/player_global/ui/sanitize_preferences()
|
||||
pref.UI_style = sanitize_inlist(pref.UI_style, all_ui_styles, initial(pref.UI_style))
|
||||
|
||||
@@ -1,141 +1,20 @@
|
||||
/datum/preferences
|
||||
var/preferences_enabled = null
|
||||
var/preferences_disabled = null
|
||||
|
||||
/datum/category_item/player_setup_item/player_global/settings
|
||||
name = "Settings"
|
||||
sort_order = 2
|
||||
|
||||
/datum/category_item/player_setup_item/player_global/settings/load_preferences(var/savefile/S)
|
||||
S["lastchangelog"] >> pref.lastchangelog
|
||||
S["lastnews"] >> pref.lastnews
|
||||
S["lastlorenews"] >> pref.lastlorenews
|
||||
S["default_slot"] >> pref.default_slot
|
||||
S["preferences"] >> pref.preferences_enabled
|
||||
S["preferences_disabled"] >> pref.preferences_disabled
|
||||
/datum/category_item/player_setup_item/player_global/settings/load_preferences(datum/json_savefile/savefile)
|
||||
pref.lastchangelog = savefile.get_entry("lastchangelog")
|
||||
pref.lastnews = savefile.get_entry("lastnews")
|
||||
pref.lastlorenews = savefile.get_entry("lastlorenews")
|
||||
pref.default_slot = savefile.get_entry("default_slot")
|
||||
|
||||
/datum/category_item/player_setup_item/player_global/settings/save_preferences(var/savefile/S)
|
||||
S["lastchangelog"] << pref.lastchangelog
|
||||
S["lastnews"] << pref.lastnews
|
||||
S["lastlorenews"] << pref.lastlorenews
|
||||
S["default_slot"] << pref.default_slot
|
||||
S["preferences"] << pref.preferences_enabled
|
||||
S["preferences_disabled"] << pref.preferences_disabled
|
||||
/datum/category_item/player_setup_item/player_global/settings/save_preferences(datum/json_savefile/savefile)
|
||||
savefile.set_entry("lastchangelog", pref.lastchangelog)
|
||||
savefile.set_entry("lastnews", pref.lastnews)
|
||||
savefile.set_entry("lastlorenews", pref.lastlorenews)
|
||||
savefile.set_entry("default_slot", pref.default_slot)
|
||||
|
||||
/datum/category_item/player_setup_item/player_global/settings/sanitize_preferences()
|
||||
// Ensure our preferences are lists.
|
||||
if(!istype(pref.preferences_enabled, /list))
|
||||
pref.preferences_enabled = list()
|
||||
if(!istype(pref.preferences_disabled, /list))
|
||||
pref.preferences_disabled = list()
|
||||
|
||||
// Arrange preferences that have never been enabled/disabled.
|
||||
var/list/client_preference_keys = list()
|
||||
for(var/datum/client_preference/client_pref as anything in get_client_preferences())
|
||||
client_preference_keys += client_pref.key
|
||||
if((client_pref.key in pref.preferences_enabled) || (client_pref.key in pref.preferences_disabled))
|
||||
continue
|
||||
|
||||
if(client_pref.enabled_by_default)
|
||||
pref.preferences_enabled += client_pref.key
|
||||
else
|
||||
pref.preferences_disabled += client_pref.key
|
||||
|
||||
// Clean out preferences that no longer exist.
|
||||
for(var/key in pref.preferences_enabled)
|
||||
if(!(key in client_preference_keys))
|
||||
pref.preferences_enabled -= key
|
||||
for(var/key in pref.preferences_disabled)
|
||||
if(!(key in client_preference_keys))
|
||||
pref.preferences_disabled -= key
|
||||
|
||||
pref.lastchangelog = sanitize_text(pref.lastchangelog, initial(pref.lastchangelog))
|
||||
pref.lastnews = sanitize_text(pref.lastnews, initial(pref.lastnews))
|
||||
pref.default_slot = sanitize_integer(pref.default_slot, 1, config.character_slots, initial(pref.default_slot))
|
||||
|
||||
/datum/category_item/player_setup_item/player_global/settings/content(var/mob/user)
|
||||
. = list()
|
||||
. += "<b>Preferences</b><br>"
|
||||
. += "<table>"
|
||||
var/mob/pref_mob = preference_mob()
|
||||
for(var/datum/client_preference/client_pref as anything in get_client_preferences())
|
||||
if(!client_pref.may_toggle(pref_mob))
|
||||
continue
|
||||
|
||||
. += "<tr><td>[client_pref.description]: </td>"
|
||||
if(pref_mob.is_preference_enabled(client_pref.key))
|
||||
. += "<td><span class='linkOn'><b>[client_pref.enabled_description]</b></span></td> <td><a href='?src=\ref[src];toggle_off=[client_pref.key]'>[client_pref.disabled_description]</a></td>"
|
||||
else
|
||||
. += "<td><a href='?src=\ref[src];toggle_on=[client_pref.key]'>[client_pref.enabled_description]</a></td> <td><span class='linkOn'><b>[client_pref.disabled_description]</b></span></td>"
|
||||
. += "</tr>"
|
||||
|
||||
. += "</table>"
|
||||
return jointext(., "")
|
||||
|
||||
/datum/category_item/player_setup_item/player_global/settings/OnTopic(var/href,var/list/href_list, var/mob/user)
|
||||
var/mob/pref_mob = preference_mob()
|
||||
if(href_list["toggle_on"])
|
||||
. = pref_mob.set_preference(href_list["toggle_on"], TRUE)
|
||||
else if(href_list["toggle_off"])
|
||||
. = pref_mob.set_preference(href_list["toggle_off"], FALSE)
|
||||
if(.)
|
||||
return TOPIC_REFRESH
|
||||
|
||||
return ..()
|
||||
|
||||
/**
|
||||
* This can take either a single preference datum or a list of preferences, and will return true if *all* preferences in the arguments are enabled.
|
||||
*/
|
||||
/client/proc/is_preference_enabled(var/preference)
|
||||
if(!islist(preference))
|
||||
preference = list(preference)
|
||||
for(var/p in preference)
|
||||
var/datum/client_preference/cp = get_client_preference(p)
|
||||
if(!prefs || !cp || !istype(cp, /datum/client_preference) || !(cp.key in prefs.preferences_enabled))
|
||||
return FALSE
|
||||
return TRUE
|
||||
|
||||
/client/proc/set_preference(var/preference, var/set_preference)
|
||||
var/datum/client_preference/cp = get_client_preference(preference)
|
||||
if(!cp)
|
||||
return FALSE
|
||||
preference = cp.key
|
||||
|
||||
if(set_preference && !(preference in prefs.preferences_enabled))
|
||||
return toggle_preference(cp)
|
||||
else if(!set_preference && (preference in prefs.preferences_enabled))
|
||||
return toggle_preference(cp)
|
||||
|
||||
/client/proc/toggle_preference(var/preference, var/set_preference)
|
||||
var/datum/client_preference/cp = get_client_preference(preference)
|
||||
if(!cp)
|
||||
return FALSE
|
||||
preference = cp.key
|
||||
|
||||
var/enabled
|
||||
if(preference in prefs.preferences_disabled)
|
||||
prefs.preferences_enabled |= preference
|
||||
prefs.preferences_disabled -= preference
|
||||
enabled = TRUE
|
||||
. = TRUE
|
||||
else if(preference in prefs.preferences_enabled)
|
||||
prefs.preferences_enabled -= preference
|
||||
prefs.preferences_disabled |= preference
|
||||
enabled = FALSE
|
||||
. = TRUE
|
||||
if(.)
|
||||
cp.toggled(mob, enabled)
|
||||
|
||||
/mob/proc/is_preference_enabled(var/preference)
|
||||
if(!client)
|
||||
return FALSE
|
||||
return client.is_preference_enabled(preference)
|
||||
|
||||
/mob/proc/set_preference(var/preference, var/set_preference)
|
||||
if(!client)
|
||||
return FALSE
|
||||
if(!client.prefs)
|
||||
log_debug("Client prefs found to be null for mob [src] and client [ckey], this should be investigated.")
|
||||
return FALSE
|
||||
|
||||
return client.set_preference(preference, set_preference)
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
|
||||
var/datum/paiCandidate/candidate
|
||||
|
||||
/datum/category_item/player_setup_item/player_global/pai/load_preferences(var/savefile/S)
|
||||
/datum/category_item/player_setup_item/player_global/pai/load_preferences(datum/json_savefile/savefile)
|
||||
if(!candidate)
|
||||
candidate = new()
|
||||
var/preference_mob = preference_mob()
|
||||
@@ -18,7 +18,7 @@
|
||||
|
||||
candidate.savefile_load(preference_mob)
|
||||
|
||||
/datum/category_item/player_setup_item/player_global/pai/save_preferences(var/savefile/S)
|
||||
/datum/category_item/player_setup_item/player_global/pai/save_preferences(datum/json_savefile/savefile)
|
||||
if(!candidate)
|
||||
return
|
||||
|
||||
|
||||
@@ -2,12 +2,12 @@
|
||||
name = "OOC"
|
||||
sort_order = 4
|
||||
|
||||
/datum/category_item/player_setup_item/player_global/ooc/load_preferences(var/savefile/S)
|
||||
S["ignored_players"] >> pref.ignored_players
|
||||
/datum/category_item/player_setup_item/player_global/ooc/load_preferences(datum/json_savefile/savefile)
|
||||
pref.ignored_players = savefile.get_entry("ignored_players")
|
||||
|
||||
|
||||
/datum/category_item/player_setup_item/player_global/ooc/save_preferences(var/savefile/S)
|
||||
S["ignored_players"] << pref.ignored_players
|
||||
/datum/category_item/player_setup_item/player_global/ooc/save_preferences(datum/json_savefile/savefile)
|
||||
savefile.set_entry("ignored_players", pref.ignored_players)
|
||||
|
||||
/*
|
||||
/datum/category_item/player_setup_item/player_global/ooc/sanitize_preferences()
|
||||
@@ -39,4 +39,4 @@
|
||||
return TOPIC_REFRESH
|
||||
|
||||
return ..()
|
||||
*/
|
||||
*/
|
||||
|
||||
@@ -1,481 +0,0 @@
|
||||
var/list/_client_preferences
|
||||
var/list/_client_preferences_by_key
|
||||
var/list/_client_preferences_by_type
|
||||
|
||||
/proc/get_client_preferences()
|
||||
if(!_client_preferences)
|
||||
_client_preferences = list()
|
||||
for(var/datum/client_preference/client_type as anything in subtypesof(/datum/client_preference))
|
||||
if(initial(client_type.description))
|
||||
_client_preferences += new client_type()
|
||||
return _client_preferences
|
||||
|
||||
/proc/get_client_preference(var/datum/client_preference/preference)
|
||||
if(istype(preference))
|
||||
return preference
|
||||
if(ispath(preference))
|
||||
return get_client_preference_by_type(preference)
|
||||
return get_client_preference_by_key(preference)
|
||||
|
||||
/proc/get_client_preference_by_key(var/preference)
|
||||
if(!_client_preferences_by_key)
|
||||
_client_preferences_by_key = list()
|
||||
for(var/datum/client_preference/client_pref as anything in get_client_preferences())
|
||||
_client_preferences_by_key[client_pref.key] = client_pref
|
||||
return _client_preferences_by_key[preference]
|
||||
|
||||
/proc/get_client_preference_by_type(var/preference)
|
||||
if(!_client_preferences_by_type)
|
||||
_client_preferences_by_type = list()
|
||||
for(var/datum/client_preference/client_pref as anything in get_client_preferences())
|
||||
_client_preferences_by_type[client_pref.type] = client_pref
|
||||
return _client_preferences_by_type[preference]
|
||||
|
||||
/datum/client_preference
|
||||
var/description
|
||||
var/key
|
||||
var/enabled_by_default = TRUE
|
||||
var/enabled_description = "Yes"
|
||||
var/disabled_description = "No"
|
||||
|
||||
/datum/client_preference/proc/may_toggle(var/mob/preference_mob)
|
||||
return TRUE
|
||||
|
||||
/datum/client_preference/proc/toggled(var/mob/preference_mob, var/enabled)
|
||||
return
|
||||
|
||||
/*********************
|
||||
* Player Preferences *
|
||||
*********************/
|
||||
|
||||
/datum/client_preference/play_admin_midis
|
||||
description ="Play admin midis"
|
||||
key = "SOUND_MIDI"
|
||||
|
||||
/datum/client_preference/play_lobby_music
|
||||
description ="Play lobby music"
|
||||
key = "SOUND_LOBBY"
|
||||
|
||||
/datum/client_preference/play_lobby_music/toggled(var/mob/preference_mob, var/enabled)
|
||||
if(!preference_mob.client || !preference_mob.client.media)
|
||||
return
|
||||
|
||||
if(enabled)
|
||||
preference_mob.client.playtitlemusic()
|
||||
else
|
||||
preference_mob.client.media.stop_music()
|
||||
|
||||
/datum/client_preference/play_ambiance
|
||||
description ="Play ambience"
|
||||
key = "SOUND_AMBIENCE"
|
||||
|
||||
/datum/client_preference/play_ambiance/toggled(var/mob/preference_mob, var/enabled)
|
||||
if(!enabled)
|
||||
preference_mob << sound(null, repeat = 0, wait = 0, volume = 0, channel = 1)
|
||||
preference_mob << sound(null, repeat = 0, wait = 0, volume = 0, channel = 2)
|
||||
//VOREStation Add - Need to put it here because it should be ordered riiiight here.
|
||||
/datum/client_preference/play_jukebox
|
||||
description ="Play jukebox music"
|
||||
key = "SOUND_JUKEBOX"
|
||||
|
||||
/datum/client_preference/play_jukebox/toggled(var/mob/preference_mob, var/enabled)
|
||||
if(!enabled)
|
||||
preference_mob.stop_all_music()
|
||||
else
|
||||
preference_mob.update_music()
|
||||
|
||||
/datum/client_preference/eating_noises
|
||||
description = "Eating Noises"
|
||||
key = "EATING_NOISES"
|
||||
enabled_description = "Noisy"
|
||||
disabled_description = "Silent"
|
||||
|
||||
/datum/client_preference/digestion_noises
|
||||
description = "Digestion Noises"
|
||||
key = "DIGEST_NOISES"
|
||||
enabled_description = "Noisy"
|
||||
disabled_description = "Silent"
|
||||
|
||||
/datum/client_preference/belch_noises // Belching noises - pref toggle for 'em
|
||||
description = "Burping"
|
||||
key = "BELCH_NOISES"
|
||||
enabled_description = "Noisy"
|
||||
disabled_description = "Silent"
|
||||
|
||||
/datum/client_preference/emote_noises
|
||||
description = "Emote Noises" //MERP
|
||||
key = "EMOTE_NOISES"
|
||||
enabled_description = "Noisy"
|
||||
disabled_description = "Silent"
|
||||
/datum/client_preference/whisubtle_vis
|
||||
description = "Whi/Subtles Ghost Visible"
|
||||
key = "WHISUBTLE_VIS"
|
||||
enabled_description = "Visible"
|
||||
disabled_description = "Hidden"
|
||||
enabled_by_default = FALSE
|
||||
|
||||
/datum/client_preference/ghost_see_whisubtle
|
||||
description = "See subtles/whispers as ghost"
|
||||
key = "GHOST_SEE_WHISUBTLE"
|
||||
enabled_description = "Visible"
|
||||
disabled_description = "Hidden"
|
||||
enabled_by_default = TRUE
|
||||
//VOREStation Add End
|
||||
/datum/client_preference/weather_sounds
|
||||
description ="Weather sounds"
|
||||
key = "SOUND_WEATHER"
|
||||
enabled_description = "Audible"
|
||||
disabled_description = "Silent"
|
||||
|
||||
/datum/client_preference/supermatter_hum
|
||||
description ="Supermatter hum"
|
||||
key = "SOUND_SUPERMATTER"
|
||||
enabled_description = "Audible"
|
||||
disabled_description = "Silent"
|
||||
|
||||
/datum/client_preference/ghost_ears
|
||||
description ="Ghost ears"
|
||||
key = "CHAT_GHOSTEARS"
|
||||
enabled_description = "All Speech"
|
||||
disabled_description = "Nearby"
|
||||
|
||||
/datum/client_preference/ghost_sight
|
||||
description ="Ghost sight"
|
||||
key = "CHAT_GHOSTSIGHT"
|
||||
enabled_description = "All Emotes"
|
||||
disabled_description = "Nearby"
|
||||
|
||||
/datum/client_preference/ghost_radio
|
||||
description ="Ghost radio"
|
||||
key = "CHAT_GHOSTRADIO"
|
||||
enabled_description = "All Chatter"
|
||||
disabled_description = "Nearby"
|
||||
|
||||
/datum/client_preference/chat_tags
|
||||
description ="Chat tags"
|
||||
key = "CHAT_SHOWICONS"
|
||||
enabled_description = "Show"
|
||||
disabled_description = "Hide"
|
||||
|
||||
/datum/client_preference/air_pump_noise
|
||||
description ="Air Pump Ambient Noise"
|
||||
key = "SOUND_AIRPUMP"
|
||||
enabled_description = "Audible"
|
||||
disabled_description = "Silent"
|
||||
|
||||
/datum/client_preference/old_door_sounds
|
||||
description ="Old Door Sounds"
|
||||
key = "SOUND_OLDDOORS"
|
||||
enabled_description = "Old"
|
||||
disabled_description = "New"
|
||||
|
||||
/datum/client_preference/department_door_sounds
|
||||
description ="Department-Specific Door Sounds"
|
||||
key = "SOUND_DEPARTMENTDOORS"
|
||||
enabled_description = "Enabled"
|
||||
disabled_description = "Disabled"
|
||||
|
||||
/datum/client_preference/pickup_sounds
|
||||
description = "Picked Up Item Sounds"
|
||||
key = "SOUND_PICKED"
|
||||
enabled_description = "Enabled"
|
||||
disabled_description = "Disabled"
|
||||
|
||||
/datum/client_preference/drop_sounds
|
||||
description = "Dropped Item Sounds"
|
||||
key = "SOUND_DROPPED"
|
||||
enabled_description = "Enabled"
|
||||
disabled_description = "Disabled"
|
||||
|
||||
/datum/client_preference/mob_tooltips
|
||||
description ="Mob tooltips"
|
||||
key = "MOB_TOOLTIPS"
|
||||
enabled_description = "Show"
|
||||
disabled_description = "Hide"
|
||||
|
||||
/datum/client_preference/inv_tooltips
|
||||
description ="Inventory tooltips"
|
||||
key = "INV_TOOLTIPS"
|
||||
enabled_description = "Show"
|
||||
disabled_description = "Hide"
|
||||
|
||||
/datum/client_preference/attack_icons
|
||||
description ="Attack icons"
|
||||
key = "ATTACK_ICONS"
|
||||
enabled_description = "Show"
|
||||
disabled_description = "Hide"
|
||||
|
||||
/datum/client_preference/precision_placement
|
||||
description ="Precision Placement"
|
||||
key = "PRECISE_PLACEMENT"
|
||||
enabled_description = "Active"
|
||||
disabled_description = "Inactive"
|
||||
|
||||
/datum/client_preference/hotkeys_default
|
||||
description ="Hotkeys Default"
|
||||
key = "HUD_HOTKEYS"
|
||||
enabled_description = "Enabled"
|
||||
disabled_description = "Disabled"
|
||||
enabled_by_default = FALSE // Backwards compatibility
|
||||
|
||||
/datum/client_preference/show_typing_indicator
|
||||
description ="Typing indicator"
|
||||
key = "SHOW_TYPING"
|
||||
enabled_description = "Show"
|
||||
disabled_description = "Hide"
|
||||
|
||||
/datum/client_preference/show_typing_indicator/toggled(var/mob/preference_mob, var/enabled)
|
||||
if(!enabled)
|
||||
preference_mob.client?.stop_thinking()
|
||||
|
||||
/datum/client_preference/show_typing_indicator_subtle
|
||||
description ="Typing indicator (subtle)"
|
||||
key = "SHOW_TYPING_SUBTLE"
|
||||
enabled_description = "Show"
|
||||
disabled_description = "Hide"
|
||||
|
||||
/datum/client_preference/show_ooc
|
||||
description ="OOC chat"
|
||||
key = "CHAT_OOC"
|
||||
enabled_description = "Show"
|
||||
disabled_description = "Hide"
|
||||
|
||||
/datum/client_preference/show_looc
|
||||
description ="LOOC chat"
|
||||
key = "CHAT_LOOC"
|
||||
enabled_description = "Show"
|
||||
disabled_description = "Hide"
|
||||
|
||||
/datum/client_preference/show_dsay
|
||||
description ="Dead chat"
|
||||
key = "CHAT_DEAD"
|
||||
enabled_description = "Show"
|
||||
disabled_description = "Hide"
|
||||
|
||||
/datum/client_preference/check_mention
|
||||
description ="Emphasize Name Mention"
|
||||
key = "CHAT_MENTION"
|
||||
enabled_description = "Emphasize"
|
||||
disabled_description = "Normal"
|
||||
|
||||
/datum/client_preference/show_progress_bar
|
||||
description ="Progress Bar"
|
||||
key = "SHOW_PROGRESS"
|
||||
enabled_description = "Show"
|
||||
disabled_description = "Hide"
|
||||
|
||||
/datum/client_preference/safefiring
|
||||
description = "Gun Firing Intent Requirement"
|
||||
key = "SAFE_FIRING"
|
||||
enabled_description = "Safe"
|
||||
disabled_description = "Dangerous"
|
||||
|
||||
/datum/client_preference/browser_style
|
||||
description = "Fake NanoUI Browser Style"
|
||||
key = "BROWSER_STYLED"
|
||||
enabled_description = "Fancy"
|
||||
disabled_description = "Plain"
|
||||
|
||||
/datum/client_preference/ambient_occlusion
|
||||
description = "Fake Ambient Occlusion"
|
||||
key = "AMBIENT_OCCLUSION_PREF"
|
||||
enabled_by_default = FALSE
|
||||
enabled_description = "On"
|
||||
disabled_description = "Off"
|
||||
|
||||
/datum/client_preference/ambient_occlusion/toggled(var/mob/preference_mob, var/enabled)
|
||||
. = ..()
|
||||
if(preference_mob && preference_mob.plane_holder)
|
||||
var/datum/plane_holder/PH = preference_mob.plane_holder
|
||||
PH.set_ao(VIS_OBJS, enabled)
|
||||
PH.set_ao(VIS_MOBS, enabled)
|
||||
|
||||
/datum/client_preference/instrument_toggle
|
||||
description ="Hear In-game Instruments"
|
||||
key = "SOUND_INSTRUMENT"
|
||||
|
||||
/datum/client_preference/vchat_enable
|
||||
description = "Enable/Disable TGChat"
|
||||
key = "VCHAT_ENABLE"
|
||||
enabled_description = "Enabled"
|
||||
disabled_description = "Disabled"
|
||||
|
||||
/datum/client_preference/status_indicators
|
||||
description = "Status Indicators"
|
||||
key = "SHOW_STATUS"
|
||||
enabled_description = "Show"
|
||||
disabled_description = "Hide"
|
||||
|
||||
/datum/client_preference/radio_sounds
|
||||
description = "Radio Sounds"
|
||||
key = "RADIO_SOUNDS"
|
||||
enabled_description = "On"
|
||||
disabled_description = "Off"
|
||||
|
||||
/datum/client_preference/say_sounds
|
||||
description = "Say Sounds"
|
||||
key = "SAY_SOUNDS"
|
||||
enabled_description = "On"
|
||||
disabled_description = "Off"
|
||||
|
||||
/datum/client_preference/emote_sounds
|
||||
description = "Me Sounds"
|
||||
key = "EMOTE_SOUNDS"
|
||||
enabled_description = "On"
|
||||
disabled_description = "Off"
|
||||
|
||||
/datum/client_preference/whisper_sounds
|
||||
description = "Whisper Sounds"
|
||||
key = "WHISPER_SOUNDS"
|
||||
enabled_description = "On"
|
||||
disabled_description = "Off"
|
||||
|
||||
/datum/client_preference/subtle_sounds
|
||||
description = "Subtle Sounds"
|
||||
key = "SUBTLE_SOUNDS"
|
||||
enabled_description = "On"
|
||||
disabled_description = "Off"
|
||||
|
||||
/datum/client_preference/vore_health_bars
|
||||
description = "Vore Health Bars"
|
||||
key = "VORE_HEALTH_BARS"
|
||||
enabled_description = "Enabled"
|
||||
disabled_description = "Disabled"
|
||||
|
||||
/datum/client_preference/runechat_mob
|
||||
description = "Runechat (Mobs)"
|
||||
key = "RUNECHAT_MOB"
|
||||
enabled_description = "Show"
|
||||
disabled_description = "Hide"
|
||||
|
||||
/datum/client_preference/runechat_obj
|
||||
description = "Runechat (Objs)"
|
||||
key = "RUNECHAT_OBJ"
|
||||
enabled_description = "Show"
|
||||
disabled_description = "Hide"
|
||||
|
||||
/datum/client_preference/runechat_border
|
||||
description = "Runechat Message Border"
|
||||
key = "RUNECHAT_BORDER"
|
||||
enabled_description = "Show"
|
||||
disabled_description = "Hide"
|
||||
enabled_by_default = TRUE
|
||||
|
||||
/datum/client_preference/runechat_long_messages
|
||||
description = "Runechat Message Length"
|
||||
key = "RUNECHAT_LONG"
|
||||
enabled_description = "Long"
|
||||
disabled_description = "Short"
|
||||
enabled_by_default = FALSE
|
||||
|
||||
/datum/client_preference/status_indicators/toggled(mob/preference_mob, enabled)
|
||||
. = ..()
|
||||
if(preference_mob && preference_mob.plane_holder)
|
||||
var/datum/plane_holder/PH = preference_mob.plane_holder
|
||||
PH.set_vis(VIS_STATUS, enabled)
|
||||
|
||||
/datum/client_preference/show_lore_news
|
||||
description = "Lore News Popup"
|
||||
key = "NEWS_POPUP"
|
||||
enabled_by_default = TRUE
|
||||
enabled_description = "Popup New On Login"
|
||||
disabled_description = "Do Nothing"
|
||||
|
||||
/datum/client_preference/play_mentorhelp_ping
|
||||
description = "Mentorhelps"
|
||||
key = "SOUND_MENTORHELP"
|
||||
enabled_description = "Hear"
|
||||
disabled_description = "Silent"
|
||||
|
||||
/datum/client_preference/player_tips
|
||||
description = "Receive Tips Periodically"
|
||||
key = "RECEIVE_TIPS"
|
||||
enabled_description = "Enabled"
|
||||
disabled_description = "Disabled"
|
||||
|
||||
/datum/client_preference/pain_frequency
|
||||
description = "Pain Messages Cooldown"
|
||||
key = "PAIN_FREQUENCY"
|
||||
enabled_by_default = FALSE
|
||||
enabled_description = "Extended"
|
||||
disabled_description = "Default"
|
||||
|
||||
/datum/client_preference/auto_afk
|
||||
description = "Automatic AFK Status"
|
||||
key = "AUTO_AFK"
|
||||
enabled_by_default = TRUE
|
||||
enabled_description = "Automatic"
|
||||
disabled_description = "Manual Only"
|
||||
|
||||
/datum/client_preference/tgui_say
|
||||
description = "TGUI Say: Use TGUI For Say Input"
|
||||
key = "TGUI_SAY"
|
||||
enabled_by_default = TRUE
|
||||
enabled_description = "Yes"
|
||||
disabled_description = "No"
|
||||
|
||||
/datum/client_preference/tgui_say_light
|
||||
description = "TGUI Say: Use Light Mode"
|
||||
key = "TGUI_SAY_LIGHT_MODE"
|
||||
enabled_by_default = FALSE
|
||||
enabled_description = "Yes"
|
||||
disabled_description = "No"
|
||||
|
||||
/********************
|
||||
* Staff Preferences *
|
||||
********************/
|
||||
/datum/client_preference/admin/may_toggle(var/mob/preference_mob)
|
||||
return check_rights(R_ADMIN|R_EVENT, 0, preference_mob)
|
||||
|
||||
/datum/client_preference/mod/may_toggle(var/mob/preference_mob)
|
||||
return check_rights(R_MOD|R_ADMIN, 0, preference_mob)
|
||||
|
||||
/datum/client_preference/debug/may_toggle(var/mob/preference_mob)
|
||||
return check_rights(R_DEBUG|R_ADMIN, 0, preference_mob)
|
||||
|
||||
/datum/client_preference/mod/show_attack_logs
|
||||
description = "Attack Log Messages"
|
||||
key = "CHAT_ATTACKLOGS"
|
||||
enabled_description = "Show"
|
||||
disabled_description = "Hide"
|
||||
enabled_by_default = FALSE
|
||||
|
||||
/datum/client_preference/debug/show_debug_logs
|
||||
description = "Debug Log Messages"
|
||||
key = "CHAT_DEBUGLOGS"
|
||||
enabled_description = "Show"
|
||||
disabled_description = "Hide"
|
||||
enabled_by_default = FALSE
|
||||
|
||||
/datum/client_preference/admin/show_chat_prayers
|
||||
description = "Chat Prayers"
|
||||
key = "CHAT_PRAYER"
|
||||
enabled_description = "Show"
|
||||
disabled_description = "Hide"
|
||||
|
||||
/datum/client_preference/holder/may_toggle(var/mob/preference_mob)
|
||||
return preference_mob && preference_mob.client && preference_mob.client.holder
|
||||
|
||||
/datum/client_preference/holder/play_adminhelp_ping
|
||||
description = "Adminhelps"
|
||||
key = "SOUND_ADMINHELP"
|
||||
enabled_description = "Hear"
|
||||
disabled_description = "Silent"
|
||||
|
||||
/datum/client_preference/holder/hear_radio
|
||||
description = "Radio chatter"
|
||||
key = "CHAT_RADIO"
|
||||
enabled_description = "Show"
|
||||
disabled_description = "Hide"
|
||||
|
||||
/datum/client_preference/holder/show_rlooc
|
||||
description ="Remote LOOC chat"
|
||||
key = "CHAT_RLOOC"
|
||||
enabled_description = "Show"
|
||||
disabled_description = "Hide"
|
||||
|
||||
/datum/client_preference/holder/show_staff_dsay
|
||||
description ="Staff Deadchat"
|
||||
key = "CHAT_ADSAY"
|
||||
enabled_description = "Show"
|
||||
disabled_description = "Hide"
|
||||
Reference in New Issue
Block a user