Files
Bubberstation/code/modules/client/preferences/glasses.dm
T
Tim b2f4cc70e9 Add glasses and icons to preference menu for nearsighted (#75642)
## About The Pull Request
This adds a few more regular glasses options to the nearsighted pref
menu:

- Random
- Jamjar
- Binoclard

It also displays the icons for the TGUI dropdown menu.

## Why It's Good For The Game
More variety and better visualization. (nearsighted... get it?)

## Changelog
🆑
qol: Add more glasses to the nearsighted pref menu with icons
/🆑

---------

Co-authored-by: ShizCalev <ShizCalev@users.noreply.github.com>
2023-05-31 14:33:52 -04:00

25 lines
792 B
Plaintext

/datum/preference/choiced/glasses
category = PREFERENCE_CATEGORY_SECONDARY_FEATURES
savefile_key = "glasses"
savefile_identifier = PREFERENCE_CHARACTER
should_generate_icons = TRUE
/datum/preference/choiced/glasses/init_possible_values()
var/list/values = list()
values["Random"] = icon('icons/effects/random_spawners.dmi', "questionmark")
for(var/glass_design in GLOB.nearsighted_glasses - "Random")
values[glass_design] = icon('icons/obj/clothing/glasses.dmi', "glasses_[lowertext(glass_design)]")
return values
/datum/preference/choiced/glasses/is_accessible(datum/preferences/preferences)
if (!..(preferences))
return FALSE
return "Nearsighted" in preferences.all_quirks
/datum/preference/choiced/glasses/apply_to_human(mob/living/carbon/human/target, value)
return