From 10e6cc852e879e04c275c9dcd3e6df2744faf8db Mon Sep 17 00:00:00 2001 From: RedWolfie <13683223+RedWolfie@users.noreply.github.com> Date: Sat, 19 Sep 2020 00:39:09 +0200 Subject: [PATCH] deletes invertHTML function (#14369) --- code/__HELPERS/unsorted.dm | 25 ------------------------- 1 file changed, 25 deletions(-) diff --git a/code/__HELPERS/unsorted.dm b/code/__HELPERS/unsorted.dm index 3fb8c2400ab..2a337c44563 100644 --- a/code/__HELPERS/unsorted.dm +++ b/code/__HELPERS/unsorted.dm @@ -20,31 +20,6 @@ return 0 -//Inverts the colour of an HTML string -/proc/invertHTML(HTMLstring) - - if(!( istext(HTMLstring) )) - CRASH("Given non-text argument!") - else - if(length(HTMLstring) != 7) - CRASH("Given non-HTML argument!") - var/textr = copytext(HTMLstring, 2, 4) - var/textg = copytext(HTMLstring, 4, 6) - var/textb = copytext(HTMLstring, 6, 8) - var/r = hex2num(textr) - var/g = hex2num(textg) - var/b = hex2num(textb) - textr = num2hex(255 - r) - textg = num2hex(255 - g) - textb = num2hex(255 - b) - if(length(textr) < 2) - textr = text("0[]", textr) - if(length(textg) < 2) - textr = text("0[]", textg) - if(length(textb) < 2) - textr = text("0[]", textb) - return text("#[][][]", textr, textg, textb) - //Returns the middle-most value /proc/dd_range(var/low, var/high, var/num) return max(low,min(high,num))