Files
Bubberstation/code/modules/client/verbs/stat_panel.dm
LT3andGitHub 523cf0ed2d Add toggle stat panel to stat panel (#6081)
## About The Pull Request

Un-hides the secret toggle-stat-panel verb
## Why It's Good For The Game

Friday somehow hid the stat panel and didn't know how to fix it. It'll
probably happen again with somebody else.

## Changelog

🆑 LT3
add: Toggle Stat Panel is now available in the OOC panel
/🆑
2026-08-08 13:51:55 -04:00

23 lines
924 B
Plaintext

/client/verb/toggle_stat_panel()
set name = "Toggle Stat Panel"
set category = "OOC" // BUBBER EDIT ADDITION - SHOW STAT PANEL TOGGLE
// set hidden = TRUE // BUBBER EDIT CHANGE - SHOW STAT PANEL TOGGLE
//Flip it
prefs.write_preference(GLOB.preference_entries[/datum/preference/toggle/statpanel], !prefs.read_preference(/datum/preference/toggle/statpanel))
set_stat_panel()
///Sets the stat panel's visibility to the player, depending on whether they need it/have it enabled or not.
/client/proc/set_stat_panel()
if(prefs.read_preference(/datum/preference/toggle/statpanel) || needs_stat_panel())
winset(src, SKIN_INFOWINDOW_CHILD, "left=statwindow")
else
winset(src, SKIN_INFOWINDOW_CHILD, "left=null")
///Returns TRUE if the player has something that necessitates the stat panel.
/client/proc/needs_stat_panel()
if(holder || interviewee)
return TRUE
. = mob.get_status_tab_items()
return length(.) >= 2