Click background in character preview to change it

This commit is contained in:
Aronai Sieyes
2020-05-22 11:07:43 -04:00
parent 70251e83f9
commit 67a5ead927
3 changed files with 22 additions and 3 deletions

View File

@@ -259,20 +259,22 @@ datum/preferences
if(!client)
return
var/obj/screen/BG= LAZYACCESS(char_render_holders, "BG")
var/obj/screen/setup_preview/bg/BG = LAZYACCESS(char_render_holders, "BG")
if(!BG)
BG = new
BG.plane = TURF_PLANE
BG.icon = 'icons/effects/128x48.dmi'
BG.pref = src
LAZYSET(char_render_holders, "BG", BG)
client.screen |= BG
BG.icon_state = bgstate
BG.screen_loc = preview_screen_locs["BG"]
for(var/D in global.cardinal)
var/obj/screen/O = LAZYACCESS(char_render_holders, "[D]")
var/obj/screen/setup_preview/O = LAZYACCESS(char_render_holders, "[D]")
if(!O)
O = new
O.pref = src
LAZYSET(char_render_holders, "[D]", O)
client.screen |= O
O.appearance = MA