mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2026-08-27 07:08:55 +01:00
[MIRROR] fixes one of my first ever coding sins here (#11720)
Co-authored-by: Kashargul <144968721+Kashargul@users.noreply.github.com>
This commit is contained in:
co-authored by
Kashargul
parent
85cd507d86
commit
65a5e0a614
@@ -508,8 +508,8 @@
|
||||
if(!user)
|
||||
return
|
||||
if(!values)
|
||||
values = list(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0)
|
||||
if(values.len < 12)
|
||||
values = DEFAULT_COLORMATRIX
|
||||
if(length(values) < 12)
|
||||
values.len = 12
|
||||
var/list/output = list()
|
||||
output += "<form><input type='hidden' name='src' value='[REF(src)]'>"
|
||||
@@ -580,8 +580,13 @@
|
||||
var/client/C = user
|
||||
user = C.mob
|
||||
else
|
||||
return
|
||||
return null
|
||||
|
||||
var/datum/browser/modal/color_matrix_picker/B = new(user, message, title, button1, button2, button3, stealfocus, timeout, values)
|
||||
B.open()
|
||||
B.wait()
|
||||
return list("button" = B.selected_button, "matrix" = B.color_matrix)
|
||||
if(B.selected_button == 3 || !B.selected_button)
|
||||
return values
|
||||
if((B.selected_button == 2) || !islist(B.color_matrix) || !ISINRANGE(length(B.color_matrix), 9, 20))
|
||||
return list()
|
||||
return B.color_matrix
|
||||
|
||||
Reference in New Issue
Block a user