mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-01-10 01:22:41 +00:00
* adds a window painting tool * Update code/game/objects/items/devices/window_painter.dm Co-authored-by: AffectedArc07 <25063394+AffectedArc07@users.noreply.github.com> * gigit * edited code to match steelslayer's suggestion * Update code/game/objects/items/devices/window_painter.dm OOF thank you for catching that Co-authored-by: AffectedArc07 <25063394+AffectedArc07@users.noreply.github.com> Co-authored-by: danni-boy <32673848+danni-boy@users.noreply.github.com> Co-authored-by: AffectedArc07 <25063394+AffectedArc07@users.noreply.github.com>
23 lines
698 B
Plaintext
23 lines
698 B
Plaintext
/obj/item/pipe_painter/window_painter
|
|
name = "window painter"
|
|
icon_state = "window_painter"
|
|
|
|
var/list/paintable_windows = list(
|
|
/obj/structure/window/reinforced,
|
|
/obj/structure/window/basic,
|
|
/obj/structure/window/full/reinforced,
|
|
/obj/structure/window/full/basic,
|
|
/obj/machinery/door/window)
|
|
|
|
/obj/item/pipe_painter/window_painter/afterattack(atom/A, mob/user as mob)
|
|
if(!is_type_in_list(A, paintable_windows) || !in_range(user, A))
|
|
return
|
|
var/obj/structure/window/W = A
|
|
|
|
if(W.color == GLOB.pipe_colors[mode])
|
|
to_chat(user, "<span class='notice'>This window is aready painted [mode]!</span>")
|
|
return
|
|
|
|
playsound(loc, usesound, 30, TRUE)
|
|
W.color = GLOB.pipe_colors[mode]
|