Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/master'
Browse files Browse the repository at this point in the history
  • Loading branch information
MosleyTheMalO committed Jul 25, 2024
2 parents 4f8b721 + e4a59e1 commit 7d0d1b3
Show file tree
Hide file tree
Showing 9 changed files with 70 additions and 9 deletions.
6 changes: 3 additions & 3 deletions code/modules/client/preferences.dm
Original file line number Diff line number Diff line change
Expand Up @@ -313,7 +313,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
///Should we be in the widescreen mode set by the config?
var/widescreenpref = TRUE
///Strip menu style
var/long_strip_menu = FALSE
var/long_strip_menu = TRUE
///What size should pixels be displayed as? 0 is strech to fit
var/pixel_size = 0
///What scaling method should we use?
Expand Down Expand Up @@ -1592,7 +1592,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
dat += "<table><tr><td width='340px' height='300px' valign='top'>"
dat += "<h2>Fetish content prefs</h2>"
dat += "<b>Allow Lewd Verbs:</b> <a href='?_src_=prefs;preference=verb_consent'>[(toggles & VERB_CONSENT) ? "Yes":"No"]</a><br>" // Skyrat - ERP Mechanic Addition
dat += "<b>Mute Lewd Verb Sounds:</b> <a href='?_src_=prefs;preference=mute_lewd_verb_sounds'>[(toggles & LEWD_VERB_SOUNDS) ? "Yes":"No"]</a><br>" // Sandstorm - ERP Mechanic Addition
dat += "<b>Lewd Verb Sounds:</b> <a href='?_src_=prefs;preference=lewd_verb_sounds'>[(toggles & LEWD_VERB_SOUNDS) ? "Yes":"No"]</a><br>" // Sandstorm - ERP Mechanic Addition
dat += "<b>Arousal:</b><a href='?_src_=prefs;preference=arousable'>[arousable == TRUE ? "Enabled" : "Disabled"]</a><BR>"
dat += "<b>Genital examine text</b>:<a href='?_src_=prefs;preference=genital_examine'>[(cit_toggles & GENITAL_EXAMINE) ? "Enabled" : "Disabled"]</a><BR>"
dat += "<b>Vore examine text</b>:<a href='?_src_=prefs;preference=vore_examine'>[(cit_toggles & VORE_EXAMINE) ? "Enabled" : "Disabled"]</a><BR>"
Expand Down Expand Up @@ -3844,7 +3844,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if("verb_consent") // Skyrat - ERP Mechanic Addition
toggles ^= VERB_CONSENT // Skyrat - ERP Mechanic Addition

if("mute_lewd_verb_sounds") // Skyrat - ERP Mechanic Addition
if("lewd_verb_sounds") // Skyrat - ERP Mechanic Addition
toggles ^= LEWD_VERB_SOUNDS // Skyrat - ERP Mechanic Addition

if("persistent_scars")
Expand Down
2 changes: 1 addition & 1 deletion code/modules/client/preferences_savefile.dm
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
// You do not need to raise this if you are adding new values that have sane defaults.
// Only raise this value when changing the meaning/format/name/layout of an existing value
// where you would want the updater procs below to run
#define SAVEFILE_VERSION_MAX 59
#define SAVEFILE_VERSION_MAX 59.1

/*
SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Carn
Expand Down
11 changes: 11 additions & 0 deletions html/changelogs/archive/2024-07.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,17 @@
SandPoot:
- rscadd: Added favorite interactions to the interaction menu, those persist between
rounds and between characters.
2024-07-21:
SandPoot:
- tweak: The healthdoll was made more responsive, for example, it will show screentips
correctly.
2024-07-22:
Fabian272:
- tweak: Fixed digilegs on polychromic workout shorts.
2024-07-24:
SandPoot:
- rscadd: Top-left menu now has lewd sounds toggle.
- tweak: The preference for lewd sounds is now about activating them, not muting.
(your preferences have been automatically flipped to account for this)
- tweak: Long strip menu is meant to be default on for sandstorm, and so it has
been set so.
35 changes: 32 additions & 3 deletions modular_sand/code/_onclick/hud/screen_objects.dm
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,38 @@
screen_loc = ui_hunger_thirst

/atom/movable/screen/healthdoll/Click(location, control, params)
var/mob/living/L = usr
usr.Click(L, control, params)
return FALSE //The health doll doesn't really do anything on it's own, change this if you need to
if(hud?.mymob)
return hud.mymob.Click(arglist(args))

/atom/movable/screen/healthdoll/examine(mob/user)
if(hud?.mymob)
return hud.mymob.examine(arglist(args))

/atom/movable/screen/healthdoll/examine_more(mob/user)
if(hud?.mymob)
return hud.mymob.examine_more(arglist(args))

/atom/movable/screen/healthdoll/MouseEntered(location, control, params)
if(hud?.mymob)
return hud.mymob.MouseEntered(arglist(args))

/atom/movable/screen/healthdoll/MouseExited(location, control, params)
if(hud?.mymob)
return hud.mymob.MouseExited(arglist(args))

/atom/movable/screen/healthdoll/MouseDown(location, control, params)
if(hud?.mymob)
return hud.mymob.MouseDown(arglist(args))

/atom/movable/screen/healthdoll/MouseUp(location, control, params)
if(hud?.mymob)
return hud.mymob.MouseUp(arglist(args))

/atom/movable/screen/healthdoll/MouseDrag(over_object, src_location, over_location, src_control, over_control, params)
if(hud?.mymob)
return hud.mymob.MouseDrag(arglist(args))

// Mousedrop won't work, behavior is usually defined on the thing that MouseDrag started on

/atom/movable/screen/sanity
name = "sanity"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -428,7 +428,7 @@

//Getting preferences
.["verb_consent"] = !!CHECK_BITFIELD(prefs.toggles, VERB_CONSENT)
.["lewd_verb_sounds"] = !CHECK_BITFIELD(prefs.toggles, LEWD_VERB_SOUNDS)
.["lewd_verb_sounds"] = !!CHECK_BITFIELD(prefs.toggles, LEWD_VERB_SOUNDS)
.["arousable"] = prefs.arousable
.["genital_examine"] = !!CHECK_BITFIELD(prefs.cit_toggles, GENITAL_EXAMINE)
.["vore_examine"] = !!CHECK_BITFIELD(prefs.cit_toggles, VORE_EXAMINE)
Expand Down
2 changes: 1 addition & 1 deletion modular_sand/code/datums/interactions/lewd_definitions.dm
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
/proc/playlewdinteractionsound(turf/turf_source, soundin, vol as num, vary, extrarange as num, frequency, falloff, channel = 0, pressure_affected = TRUE, sound/S, envwet = -10000, envdry = 0, manual_x, manual_y, list/ignored_mobs)
var/list/hearing_mobs
for(var/mob/H in get_hearers_in_view(4, turf_source))
if(!H.client || (H.client.prefs.toggles & LEWD_VERB_SOUNDS))
if(!H.client || !(H.client.prefs.toggles & LEWD_VERB_SOUNDS))
continue
LAZYADD(hearing_mobs, H)
if(ignored_mobs?.len)
Expand Down
7 changes: 7 additions & 0 deletions modular_sand/code/modules/client/preferences_savefile.dm
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,13 @@
if(CHECK_BITFIELD(toggles, SOUND_BARK))
DISABLE_BITFIELD(toggles, SOUND_BARK)
ENABLE_BITFIELD(toggles, VERB_CONSENT)

if(current_version < 59.1)
// Just invert it, now it's a switch to see if you want it on, rather than off.
TOGGLE_BITFIELD(toggles, LEWD_VERB_SOUNDS)

// It may not be a default on cit, but this is meant to be default here at least.
long_strip_menu = TRUE
. = ..()

/datum/preferences/save_preferences(bypass_cooldown, silent)
Expand Down
13 changes: 13 additions & 0 deletions modular_sand/code/modules/client/preferences_toggles.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
TOGGLE_CHECKBOX(/datum/verbs/menu/Settings/Sound, toggle_lewd_sounds)()
set name = "Hear/Silence Lewd Verb Sounds"
set category = "Preferences"
set desc = "Hear Lewd Verb Sounds From Interactions"
usr.client.prefs.toggles ^= LEWD_VERB_SOUNDS
usr.client.prefs.save_preferences()
if(usr.client.prefs.toggles & LEWD_VERB_SOUNDS)
to_chat(usr, "You will now hear lewd verb sounds.")
else
to_chat(usr, "You will no longer hear lewd verb sounds")
SSblackbox.record_feedback("nested tally", "preferences_verb", 1, list("Toggle Hearing Lewd Verb Sounds", "[usr.client.prefs.toggles & LEWD_VERB_SOUNDS ? "Enabled" : "Disabled"]")) //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/datum/verbs/menu/Settings/Sound/toggle_lewd_sounds/Get_checked(client/C)
return C.prefs.toggles & LEWD_VERB_SOUNDS
1 change: 1 addition & 0 deletions tgstation.dme
Original file line number Diff line number Diff line change
Expand Up @@ -4217,6 +4217,7 @@
#include "modular_sand\code\modules\client\client_procs.dm"
#include "modular_sand\code\modules\client\preferences.dm"
#include "modular_sand\code\modules\client\preferences_savefile.dm"
#include "modular_sand\code\modules\client\preferences_toggles.dm"
#include "modular_sand\code\modules\client\loadout\_security.dm"
#include "modular_sand\code\modules\client\loadout\accessories.dm"
#include "modular_sand\code\modules\client\loadout\backpack.dm"
Expand Down

0 comments on commit 7d0d1b3

Please sign in to comment.