[MIRROR] Status Displays can be taken down [MDB IGNORE] (#8698)

* Status Displays can be taken down (#61847)

Co-authored-by: Mothblocks <35135081+Mothblocks@ users.noreply.github.com>

* Status Displays can be taken down

Co-authored-by: Mooshimi <85910816+Mooshimi@users.noreply.github.com>
Co-authored-by: Mothblocks <35135081+Mothblocks@ users.noreply.github.com>
This commit is contained in:
SkyratBot
2021-10-09 03:38:28 +02:00
committed by GitHub
parent c3dc82810e
commit ecfb1881c2
4 changed files with 64 additions and 0 deletions
+56
View File
@@ -18,6 +18,10 @@
desc = null
icon = 'icons/obj/status_display.dmi' //ICON OVERRIDEN IN SKYRAT AESTHETICS - SEE MODULE
icon_state = "frame"
base_icon_state = "unanchoredstatusdisplay"
verb_say = "beeps"
verb_ask = "beeps"
verb_exclaim = "beeps"
density = FALSE
use_power = IDLE_POWER_USE
idle_power_usage = 10
@@ -32,6 +36,49 @@
var/index1 // display index for scrolling messages or 0 if non-scrolling
var/index2
/obj/item/wallframe/status_display
name = "status display frame"
desc = "Used to build status displays, just secure to the wall."
icon_state = "unanchoredstatusdisplay"
custom_materials = list(/datum/material/iron=14000, /datum/material/glass=8000)
result_path = /obj/machinery/status_display
/obj/machinery/status_display/wrench_act_secondary(mob/living/user, obj/item/tool)
. = ..()
balloon_alert(user, "[anchored ? "un" : ""]securing...")
tool.play_tool_sound(src)
if(tool.use_tool(src, user, 6 SECONDS))
playsound(loc, 'sound/items/deconstruct.ogg', 50, TRUE)
balloon_alert(user, "[anchored ? "un" : ""]secured")
deconstruct()
return TRUE
/obj/machinery/status_display/welder_act(mob/living/user, obj/item/tool)
if(user.combat_mode)
return
if(atom_integrity >= max_integrity)
balloon_alert(user, "it doesn't need repairs!")
return TRUE
user.balloon_alert_to_viewers("repairing display...", "repairing...")
if(!tool.use_tool(src, user, 4 SECONDS, amount = 0, volume=50))
return TRUE
balloon_alert(user, "repaired")
atom_integrity = max_integrity
set_machine_stat(machine_stat & ~BROKEN)
update_appearance()
return TRUE
/obj/machinery/status_display/deconstruct(disassembled = TRUE)
if(flags_1 & NODECONSTRUCT_1)
return
if(!disassembled)
new /obj/item/stack/sheet/iron(drop_location(), 2)
new /obj/item/shard(drop_location())
new /obj/item/shard(drop_location())
else
new /obj/item/wallframe/status_display(drop_location())
qdel(src)
/// Immediately blank the display.
/obj/machinery/status_display/proc/remove_display()
cut_overlays()
@@ -175,6 +222,15 @@
dir = EAST
pixel_x = -32
//makes it go on the wall when built
/obj/machinery/status_display/Initialize(mapload, ndir, building)
. = ..()
if(building)
setDir(ndir)
pixel_x = NSCOMPONENT(dir) ? 0 : (dir == EAST ? -world.icon_size : world.icon_size)
pixel_y = NSCOMPONENT(dir) ? (dir == NORTH ? -world.icon_size : world.icon_size) : 0
update_appearance()
/obj/machinery/status_display/evac/Initialize(mapload)
. = ..()
// register for radio system
@@ -778,6 +778,14 @@
build_path = /obj/item/wallframe/newscaster
category = list("initial", "Construction")
/datum/design/status_display_frame
name = "Status Display Frame"
id = "status_display_frame"
build_type = AUTOLATHE
materials = list(/datum/material/iron = 14000, /datum/material/glass = 8000)
build_path = /obj/item/wallframe/status_display
category = list("initial", "Construction")
/datum/design/bounty_board_frame
name = "Bounty Board Frame"
id = "bountyboard_frame"
Binary file not shown.

Before

Width:  |  Height:  |  Size: 25 KiB

After

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

After

Width:  |  Height:  |  Size: 1.3 KiB