From b9223e84f73578811ee528de5ce41560d0ef8d72 Mon Sep 17 00:00:00 2001 From: EvilDragonfiend <87972842+EvilDragonfiend@users.noreply.github.com> Date: Sat, 2 Dec 2023 03:34:58 +0900 Subject: [PATCH] color fix (#10229) --- code/__DEFINES/colors.dm | 10 ++++++++++ code/modules/holoparasite/_holoparasite.dm | 2 +- code/modules/holoparasite/holoparasite_builder.dm | 4 ++-- code/modules/holoparasite/holoparasite_setters.dm | 2 +- 4 files changed, 14 insertions(+), 4 deletions(-) diff --git a/code/__DEFINES/colors.dm b/code/__DEFINES/colors.dm index acea30517e537..979ce88828523 100644 --- a/code/__DEFINES/colors.dm +++ b/code/__DEFINES/colors.dm @@ -100,6 +100,16 @@ GLOBAL_LIST_INIT(color_list_blood_brothers, shuffle(list( "cfc_orange",\ "cfc_redorange"))) +// Do not use this as a font color. try cfc color formats. +GLOBAL_LIST_INIT(color_list_rainbow, list( + "#FF5050",\ + "#FF902A",\ + "#D6B20C",\ + "#88d818",\ + "#42c9eb",\ + "#422ED8",\ + "#D977FD")) + // Color Filters /// Icon filter that creates ambient occlusion #define AMBIENT_OCCLUSION filter(type="drop_shadow", x=0, y=-2, size=4, color="#04080FAA") diff --git a/code/modules/holoparasite/_holoparasite.dm b/code/modules/holoparasite/_holoparasite.dm index c62ca9a67d3b2..5cf6faf6bc22d 100644 --- a/code/modules/holoparasite/_holoparasite.dm +++ b/code/modules/holoparasite/_holoparasite.dm @@ -111,7 +111,7 @@ GLOBAL_LIST_EMPTY_TYPED(holoparasites, /mob/living/simple_animal/hostile/holopar stack_trace("Holoparasite initialized without a valid theme!") return INITIALIZE_HINT_QDEL GLOB.holoparasites += src - set_accent_color(_accent_color || pick(GLOB.color_list_blood_brothers), silent = TRUE) + set_accent_color(_accent_color || pick(GLOB.color_list_rainbow), silent = TRUE) set_theme(_theme) if(length(_name)) set_name(_name, internal = TRUE) diff --git a/code/modules/holoparasite/holoparasite_builder.dm b/code/modules/holoparasite/holoparasite_builder.dm index 66a7cfc2e11e6..fe4eb2c998e41 100644 --- a/code/modules/holoparasite/holoparasite_builder.dm +++ b/code/modules/holoparasite/holoparasite_builder.dm @@ -43,7 +43,7 @@ if(isnum_safe(_uses)) uses = max(round(_uses), 1) debug_mode = _debug_mode - accent_color = pick(GLOB.color_list_blood_brothers) + accent_color = pick(GLOB.color_list_rainbow) /datum/holoparasite_builder/Destroy() QDEL_NULL(saved_stats) @@ -195,7 +195,7 @@ var/color = params["color"] if(!istext(color) || length(color) != 7) return - var/new_accent_color = sanitize_hexcolor(color, desired_format = 6, include_crunch = TRUE, default = (length(accent_color) == 7 && accent_color != initial(accent_color)) ? accent_color : pick(GLOB.color_list_blood_brothers)) + var/new_accent_color = sanitize_hexcolor(color, desired_format = 6, include_crunch = TRUE, default = (length(accent_color) == 7 && accent_color != initial(accent_color)) ? accent_color : pick(GLOB.color_list_rainbow)) if(is_color_dark_with_saturation(new_accent_color, HOLOPARA_MAX_ACCENT_LIGHTNESS)) to_chat(usr, "Selected accent color is too dark!") return diff --git a/code/modules/holoparasite/holoparasite_setters.dm b/code/modules/holoparasite/holoparasite_setters.dm index 92e2353b5ad42..101777a6fb9b8 100644 --- a/code/modules/holoparasite/holoparasite_setters.dm +++ b/code/modules/holoparasite/holoparasite_setters.dm @@ -72,7 +72,7 @@ if(!new_color) return FALSE var/old_accent_color = accent_color - new_color = sanitize_hexcolor(new_color, desired_format = 6, include_crunch = TRUE, default = (length(old_accent_color) == 7 && old_accent_color != initial(accent_color)) ? old_accent_color : pick(GLOB.color_list_blood_brothers)) + new_color = sanitize_hexcolor(new_color, desired_format = 6, include_crunch = TRUE, default = (length(old_accent_color) == 7 && old_accent_color != initial(accent_color)) ? old_accent_color : pick(GLOB.color_list_rainbow)) accent_color = new_color chat_color = new_color if(tracking_beacon)