mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-24 04:27:35 +01:00
New TEG sprites (#18085)
* amogus
* Revert "amogus"
This reverts commit ebaa99c77b.
* T E Gee
:D
* adjusts sprites slightly
TEGs taller now, I though they looked too short b4
* makes pipe connection nicer
* Emissive Devices
yep
* suggested changes
Moved update_icon() call out of atmos/process, which was calling it multiple times a second, and into return_transfer_air() which is the only place where the critical variable is redefined.
* readds conflicted changes
* bruh
* SteelSlayer Suggestion
Co-authored-by: SteelSlayer <42044220+SteelSlayer@users.noreply.github.com>
* removes duplicate proc
Co-authored-by: SteelSlayer <42044220+SteelSlayer@users.noreply.github.com>
This commit is contained in:
@@ -16,6 +16,9 @@
|
||||
var/lastgenlev = -1
|
||||
var/lastcirc = "00"
|
||||
|
||||
var/light_range_on = 1
|
||||
var/light_power_on = 0.1 //just dont want it to be culled by byond.
|
||||
|
||||
/obj/machinery/power/generator/Initialize(mapload)
|
||||
. = ..()
|
||||
update_desc()
|
||||
@@ -36,6 +39,10 @@
|
||||
if(powernet)
|
||||
disconnect_from_network()
|
||||
|
||||
/obj/machinery/power/generator/Initialize()
|
||||
. = ..()
|
||||
connect()
|
||||
|
||||
/obj/machinery/power/generator/proc/connect()
|
||||
connect_to_network()
|
||||
|
||||
@@ -60,21 +67,29 @@
|
||||
updateDialog()
|
||||
|
||||
/obj/machinery/power/generator/power_change()
|
||||
. = ..()
|
||||
if(!anchored)
|
||||
stat |= NOPOWER
|
||||
if((stat & (BROKEN|NOPOWER)))
|
||||
set_light(0)
|
||||
else
|
||||
..()
|
||||
set_light(light_range_on, light_power_on)
|
||||
update_icon()
|
||||
|
||||
|
||||
/obj/machinery/power/generator/update_icon()
|
||||
if(stat & (NOPOWER|BROKEN))
|
||||
overlays.Cut()
|
||||
cut_overlays()
|
||||
underlays.Cut()
|
||||
return
|
||||
else
|
||||
overlays.Cut()
|
||||
|
||||
cut_overlays()
|
||||
if(lastgenlev != 0)
|
||||
overlays += image('icons/obj/power.dmi', "teg-op[lastgenlev]")
|
||||
add_overlay(mutable_appearance('icons/obj/power.dmi', "teg-op[lastgenlev]"))
|
||||
underlays += emissive_appearance(icon, "teg-op[lastgenlev]")
|
||||
|
||||
overlays += image('icons/obj/power.dmi', "teg-oc[lastcirc]")
|
||||
add_overlay(mutable_appearance('icons/obj/power.dmi', "teg-oc[lastcirc]"))
|
||||
underlays += emissive_appearance(icon, "teg-oc[lastcirc]")
|
||||
|
||||
/obj/machinery/power/generator/process()
|
||||
if(stat & (NOPOWER|BROKEN))
|
||||
@@ -230,7 +245,3 @@
|
||||
if(!powernet || !cold_circ || !hot_circ)
|
||||
connect()
|
||||
return TRUE
|
||||
|
||||
/obj/machinery/power/generator/power_change()
|
||||
..()
|
||||
update_icon()
|
||||
|
||||
Reference in New Issue
Block a user