More glowy

This commit is contained in:
Aronai Sieyes
2021-07-02 21:34:52 -04:00
parent 028bee93d4
commit c4dfdadcae
7 changed files with 76 additions and 24 deletions
+19 -6
View File
@@ -28,7 +28,7 @@
name = "alarm"
desc = "Used to control various station atmospheric systems. The light indicates the current air status of the area."
icon = 'icons/obj/monitors_vr.dmi' //VOREStation Edit - Other icons
icon_state = "alarm0"
icon_state = "alarm_0"
layer = ABOVE_WINDOW_LAYER
vis_flags = VIS_HIDE // They have an emissive that looks bad in openspace due to their wall-mounted nature
anchored = 1
@@ -39,6 +39,8 @@
req_one_access = list(access_atmospherics, access_engine_equip)
clicksound = "button"
clickvol = 30
blocks_emissive = NONE
light_power = 0.25
var/alarm_id = null
var/breach_detection = 1 // Whether to use automatic breach detection or not
var/frequency = 1439
@@ -132,10 +134,10 @@
TLV["pressure"] = list(ONE_ATMOSPHERE * 0.80, ONE_ATMOSPHERE * 0.90, ONE_ATMOSPHERE * 1.10, ONE_ATMOSPHERE * 1.20) /* kpa */
TLV["temperature"] = list(T0C - 26, T0C, T0C + 40, T0C + 66) // K
//VOREStation Add
pixel_x = (src.dir & 3)? 0 : (src.dir == 4 ? -28 : 28)
pixel_y = (src.dir & 3)? (src.dir ==1 ? -28 : 28) : 0
//VOREStation Add End
update_icon()
/obj/machinery/alarm/Initialize()
. = ..()
@@ -299,13 +301,17 @@
return 0
/obj/machinery/alarm/update_icon()
cut_overlays()
if(panel_open)
icon_state = "alarmx"
set_light(0)
set_light_on(FALSE)
return
if((stat & (NOPOWER|BROKEN)) || shorted)
icon_state = "alarmp"
set_light(0)
set_light_on(FALSE)
return
var/icon_level = danger_level
@@ -315,16 +321,23 @@
var/new_color = null
switch(icon_level)
if(0)
icon_state = "alarm0"
icon_state = "alarm_0"
add_overlay(mutable_appearance(icon, "alarm_ov0"))
add_overlay(emissive_appearance(icon, "alarm_ov0"))
new_color = "#03A728"
if(1)
icon_state = "alarm2" //yes, alarm2 is yellow alarm
icon_state = "alarm_2" //yes, alarm2 is yellow alarm
add_overlay(mutable_appearance(icon, "alarm_ov2"))
add_overlay(emissive_appearance(icon, "alarm_ov2"))
new_color = "#EC8B2F"
if(2)
icon_state = "alarm1"
icon_state = "alarm_1"
add_overlay(mutable_appearance(icon, "alarm_ov1"))
add_overlay(emissive_appearance(icon, "alarm_ov1"))
new_color = "#DA0205"
set_light(l_range = 2, l_power = 0.25, l_color = new_color)
set_light_on(TRUE)
/obj/machinery/alarm/receive_signal(datum/signal/signal)
if(stat & (NOPOWER|BROKEN))
+17 -3
View File
@@ -129,6 +129,10 @@ GLOBAL_LIST_BOILERPLATE(allCasters, /obj/machinery/newscaster)
icon = 'icons/obj/terminals_vr.dmi' //VOREStation Edit
icon_state = "newscaster_normal"
layer = ABOVE_WINDOW_LAYER
blocks_emissive = NONE
light_power = 0.9
light_range = 2
light_color = "#00ff00"
var/isbroken = 0 //1 if someone banged it with something heavy
var/ispowered = 1 //starts powered, changes with power_change()
//var/list/datum/feed_channel/channel_list = list() //This list will contain the names of the feed channels. Each name will refer to a data region where the messages of the feed channels are stored.
@@ -176,6 +180,7 @@ GLOBAL_LIST_BOILERPLATE(allCasters, /obj/machinery/newscaster)
/obj/machinery/newscaster/LateInitialize()
node = get_exonet_node()
update_icon()
/obj/machinery/newscaster/Destroy()
allCasters -= src
@@ -183,25 +188,34 @@ GLOBAL_LIST_BOILERPLATE(allCasters, /obj/machinery/newscaster)
return ..()
/obj/machinery/newscaster/update_icon()
cut_overlays()
if(!ispowered || isbroken)
icon_state = "newscaster_off"
if(isbroken) //If the thing is smashed, add crack overlay on top of the unpowered sprite.
cut_overlays()
add_overlay("crack3")
set_light(0)
set_light_on(FALSE)
return
cut_overlays() //reset overlays
if(news_network.wanted_issue) //wanted icon state, there can be no overlays on it as it's a priority message
icon_state = "newscaster_wanted"
add_overlay(mutable_appearance(icon, "newscaster_wanted_ov"))
add_overlay(emissive_appearance(icon, "newscaster_wanted_ov"))
return
if(alert) //new message alert overlay
add_overlay("newscaster_alert")
add_overlay(mutable_appearance(icon, "newscaster_alert"))
add_overlay(emissive_appearance(icon, "newscaster_alert"))
if(hitstaken > 0) //Cosmetic damage overlay
add_overlay("crack[hitstaken]")
icon_state = "newscaster_normal"
add_overlay(emissive_appearance(icon, "newscaster_normal_ov"))
add_overlay(mutable_appearance(icon, "newscaster_normal_ov"))
set_light(2)
set_light_on(TRUE)
return
/obj/machinery/newscaster/power_change()
+24 -15
View File
@@ -30,6 +30,9 @@ var/list/obj/machinery/requests_console/allConsoles = list()
icon_state = "req_comp0"
layer = ABOVE_WINDOW_LAYER
circuit = /obj/item/weapon/circuitboard/request
blocks_emissive = NONE
light_power = 0.25
light_color = "#00ff00"
var/department = "Unknown" //The list of all departments on the station (Determined from this variable on each unit) Set this to the same thing if you want several consoles in one department
var/list/message_log = list() //List of all messages
var/departmentType = 0 //Bitflag. Zero is reply-only. Map currently uses raw numbers instead of defines.
@@ -55,20 +58,8 @@ var/list/obj/machinery/requests_console/allConsoles = list()
light_range = 0
var/datum/announcement/announcement = new
/obj/machinery/requests_console/power_change()
..()
update_icon()
/obj/machinery/requests_console/update_icon()
if(stat & NOPOWER)
if(icon_state != "req_comp_off")
icon_state = "req_comp_off"
else
if(icon_state == "req_comp_off")
icon_state = "req_comp[newmessagepriority]"
/obj/machinery/requests_console/New()
..()
/obj/machinery/requests_console/Initialize()
. = ..()
announcement.title = "[department] announcement"
announcement.newscast = 1
@@ -82,7 +73,7 @@ var/list/obj/machinery/requests_console/allConsoles = list()
if(departmentType & RC_INFO)
req_console_information |= department
set_light(1)
update_icon()
/obj/machinery/requests_console/Destroy()
allConsoles -= src
@@ -100,6 +91,24 @@ var/list/obj/machinery/requests_console/allConsoles = list()
req_console_information -= department
return ..()
/obj/machinery/requests_console/power_change()
..()
update_icon()
/obj/machinery/requests_console/update_icon()
cut_overlays()
if(stat & NOPOWER)
set_light(0)
set_light_on(FALSE)
icon_state = "req_comp_off"
else
icon_state = "req_comp_[newmessagepriority]"
add_overlay(mutable_appearance(icon, "req_comp_ov[newmessagepriority]"))
add_overlay(emissive_appearance(icon, "req_comp_ov[newmessagepriority]"))
set_light(2)
set_light_on(TRUE)
/obj/machinery/requests_console/attack_hand(user as mob)
if(..(user))
return
@@ -8,6 +8,9 @@
w_class = ITEMSIZE_LARGE
canhear_range = 7 //VOREStation Edit
flags = NOBLOODY
light_color = "#00ff00"
light_power = 0.25
blocks_emissive = NONE
var/circuit = /obj/item/weapon/circuitboard/intercom
var/number = 0
var/wiresexposed = 0
@@ -17,6 +20,7 @@
var/area/A = get_area(src)
if(A)
GLOB.apc_event.register(A, src, /atom/proc/update_icon)
update_icon()
/obj/item/device/radio/intercom/Destroy()
var/area/A = get_area(src)
@@ -51,11 +55,13 @@
/obj/item/device/radio/intercom/department/medbay
name = "station intercom (Medbay)"
icon_state = "medintercom"
light_color = "#00aaff"
frequency = MED_I_FREQ
/obj/item/device/radio/intercom/department/security
name = "station intercom (Security)"
icon_state = "secintercom"
light_color = "#ff0000"
frequency = SEC_I_FREQ
/obj/item/device/radio/intercom/entertainment
@@ -166,8 +172,12 @@
/obj/item/device/radio/intercom/update_icon()
var/area/A = get_area(src)
on = A?.powered(EQUIP)
cut_overlays()
if(!on)
set_light(0)
set_light_on(FALSE)
if(wiresexposed)
icon_state = "intercom-p_open"
else
@@ -175,8 +185,14 @@
else
if(wiresexposed)
icon_state = "intercom_open"
set_light(0)
set_light_on(FALSE)
else
icon_state = initial(icon_state)
add_overlay(mutable_appearance(icon, "[icon_state]_ov"))
add_overlay(emissive_appearance(icon, "[icon_state]_ov"))
set_light(2)
set_light_on(TRUE)
//VOREStation Add Start
/obj/item/device/radio/intercom/AICtrlClick(var/mob/user)
Binary file not shown.

Before

Width:  |  Height:  |  Size: 28 KiB

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 28 KiB

After

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 17 KiB

After

Width:  |  Height:  |  Size: 17 KiB