mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-27 23:27:34 +01:00
Optimize cardboard cutouts saving 1.5s+ on init times (#73404)
New regression in init times. Closes https://github.com/tgstation/dev-cycles-initiative/issues/32. CC @Fikou - Instead of creating a human and icon for *every* cardboard cutout when initialized, only creates the one we're actually using. When you're about to use a crayon, creates all of them. - Instead of using getFlatIcon, uses appearances directly.
This commit is contained in:
@@ -32,7 +32,7 @@
|
||||
|
||||
/mob/living/basic/syndicate/Initialize(mapload)
|
||||
. = ..()
|
||||
apply_dynamic_human_icon(src, mob_spawn_path = mob_spawner, r_hand = r_hand, l_hand = l_hand)
|
||||
apply_dynamic_human_appearance(src, mob_spawn_path = mob_spawner, r_hand = r_hand, l_hand = l_hand)
|
||||
if(LAZYLEN(loot))
|
||||
AddElement(/datum/element/death_drops, loot)
|
||||
AddElement(/datum/element/footstep, footstep_type = FOOTSTEP_MOB_SHOE)
|
||||
|
||||
Reference in New Issue
Block a user