mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-19 11:05:03 +01:00
we got COLORS (#30082)
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
/// The datum we are modifying. This will almost always be an atom, but clients have colours too
|
||||
var/datum/target_datum
|
||||
// Target colour matrix to make applying easier
|
||||
var/target_matrix = list(
|
||||
var/list/target_matrix = list(
|
||||
1, 0, 0, 0,
|
||||
0, 1, 0, 0,
|
||||
0, 0, 1, 0,
|
||||
@@ -18,6 +18,13 @@
|
||||
return
|
||||
|
||||
target_datum = target
|
||||
if(islist(target:color))
|
||||
target_matrix = target:color
|
||||
target_matrix.Cut(17, 0) // get down to a 4x4 matrix
|
||||
else if(istext(target:color))
|
||||
target_matrix[1] = GETREDPART(target:color) / 255
|
||||
target_matrix[6] = GETGREENPART(target:color) / 255
|
||||
target_matrix[11] = GETBLUEPART(target:color) / 255
|
||||
|
||||
/datum/ui_module/colour_matrix_tester/ui_state(mob/user)
|
||||
return GLOB.admin_state
|
||||
|
||||
Reference in New Issue
Block a user