Redoes how appearance VV works because it scares me (#82851)

This commit is contained in:
LemonInTheDark
2024-04-24 16:23:54 -06:00
committed by GitHub
parent bdab65dfc3
commit 21b6abfcd6
7 changed files with 235 additions and 371 deletions
@@ -30,6 +30,9 @@
// This is split into a seperate proc mostly to make errors that happen not break things too much
/proc/_debug_variable_value(name, value, level, datum/owner, sanitize, display_flags)
if(isappearance(value))
value = get_vv_appearance(value)
. = "<font color='red'>DISPLAY_ERROR:</font> ([value] [REF(value)])" // Make sure this line can never runtime
if(isnull(value))
@@ -49,13 +52,6 @@
return "/icon (<span class='value'>[value]</span>)"
#endif
if(isappearance(value)) // Reminder: Do not replace this into /image/debug_variable_value() proc. /appearance can't do that.
return "<a href='?_src_=vars;[HrefToken()];Vars=[REF(value)]'>/appearance (<span class='value'>[get_appearance_vv_summary_name(value)]</span>) [REF(value)]</a>"
if(isimage(value))
return "<a href='?_src_=vars;[HrefToken()];Vars=[REF(value)]'>[value:type] (<span class='value'>[get_appearance_vv_summary_name(value)]</span>) [REF(value)]</a>"
if(isfilter(value))
var/datum/filter_value = value
return "/filter (<span class='value'>[filter_value.type] [REF(filter_value)]</span>)"