mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-23 21:12:24 +01:00
Human icon key & preferences tweaks (#3274)
changes: Reworked how human body icon keys are generated; resulting keys should be much shorter now and involve less duplication of the same string. Players are now shown a message when they try to add markings to a species that has none available. Admin revive for human-types will now also re-apply their organ and marking prefs. Admin revive now also resets shock_stage (fixes rejuv'd mobs being slow for a while)
This commit is contained in:
@@ -52,6 +52,8 @@
|
||||
var/list/human_underwear_cache = list()
|
||||
var/list/human_undershirt_cache = list()
|
||||
var/list/human_socks_cache = list()
|
||||
var/list/organ_keymap = list()
|
||||
var/current_organ_keymap_idex = 1
|
||||
// This is an assoc list of all icon states in `icons/mob/collar.dmi`, used by human update-icons.
|
||||
var/list/collar_states
|
||||
var/list/uniform_states
|
||||
@@ -64,6 +66,16 @@
|
||||
for (var/i in icon_states('icons/mob/collar.dmi'))
|
||||
collar_states[i] = TRUE
|
||||
|
||||
/datum/controller/subsystem/icon_cache/proc/get_organ_shortcode(obj/item/organ/external/organ)
|
||||
if (QDELETED(organ))
|
||||
return null
|
||||
|
||||
var/key = organ.get_mob_cache_key(FALSE)
|
||||
. = organ_keymap[key]
|
||||
if (!.)
|
||||
organ_keymap[key] = "organ[current_organ_keymap_idex++]"
|
||||
. = organ_keymap[key]
|
||||
|
||||
/datum/controller/subsystem/icon_cache/proc/setup_uniform_mappings()
|
||||
uniform_states = list()
|
||||
for (var/i in icon_states('icons/mob/uniform.dmi'))
|
||||
|
||||
Reference in New Issue
Block a user