mirror of
https://github.com/KabKebab/GS13.git
synced 2026-07-12 16:38:18 +01:00
spray paint update
This commit is contained in:
@@ -678,13 +678,20 @@
|
||||
|
||||
return
|
||||
|
||||
if(istype(target, /obj/structure/window))
|
||||
if(isobj(target))
|
||||
if(actually_paints)
|
||||
if(color_hex2num(paint_color) < 350 && !istype(target, /obj/structure/window) && !istype(target, /obj/effect/decal/cleanable/crayon)) //Colors too dark are rejected
|
||||
to_chat(usr, "<span class='warning'>A color that dark on an object like this? Surely not...</span>")
|
||||
return FALSE
|
||||
|
||||
target.add_atom_colour(paint_color, WASHABLE_COLOUR_PRIORITY)
|
||||
if(color_hex2num(paint_color) < 255)
|
||||
target.set_opacity(255)
|
||||
else
|
||||
target.set_opacity(initial(target.opacity))
|
||||
|
||||
if(istype(target, /obj/structure/window))
|
||||
if(color_hex2num(paint_color) < 255)
|
||||
target.set_opacity(255)
|
||||
else
|
||||
target.set_opacity(initial(target.opacity))
|
||||
|
||||
. = use_charges(user, 2)
|
||||
var/fraction = min(1, . / reagents.maximum_volume)
|
||||
reagents.reaction(target, TOUCH, fraction * volume_multiplier)
|
||||
@@ -692,6 +699,7 @@
|
||||
|
||||
if(pre_noise || post_noise)
|
||||
playsound(user.loc, 'sound/effects/spray.ogg', 5, 1, 5)
|
||||
user.visible_message("[user] coats [target] with spray paint!", "<span class='notice'>You coat [target] with spray paint.</span>")
|
||||
return
|
||||
|
||||
. = ..()
|
||||
|
||||
@@ -323,6 +323,8 @@
|
||||
var/BR = brightness
|
||||
var/PO = bulb_power
|
||||
var/CO = bulb_colour
|
||||
if(color)
|
||||
CO = color
|
||||
var/area/A = get_area(src)
|
||||
if (A && A.fire)
|
||||
CO = bulb_emergency_colour
|
||||
@@ -360,6 +362,9 @@
|
||||
else
|
||||
removeStaticPower(static_power_used, STATIC_LIGHT)
|
||||
|
||||
/obj/machinery/light/update_atom_colour()
|
||||
. = ..()
|
||||
update()
|
||||
|
||||
/obj/machinery/light/process()
|
||||
if (!cell)
|
||||
|
||||
Reference in New Issue
Block a user