mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-26 13:37:58 +01:00
Port TG updating appearances (#17943)
* Get pants that match or else you gonna look silly yo
* Posters
* Fix other hud elements
* Rereviewed
* Update shotglass.dm
* Fix for new merged PRs
* Typo
* Coming across other stuff
* Update theblob.dm
* No takebacksies
* smh i forget to leave a comment
* Updated for the detgun and cards
* Should have rerun langserver again
* No longer plastic, more in scope
* Damn you bluespace
* Reverting turret logic, out of scope at this point
* Tweak that part
* Went over energy guns again, and fixed UI White's sprite sheet
* Welding masks, glasses, and JUSTICE
* Update portable_atmospherics.dm
* Cleaning up, clearing things up
* Review and suggestions
* Update valve.dm
* More tweaks
* Missing character
* Not distinct lightmasks, so they can be overlays
* Update generator.dm
* Add parameter so holodeck doesn't try to make a perfect copy
* Update unsorted.dm
* Spiders
* Better fix for spiders, fix vamps too
* Ghosts
* Update telekinesis.dm
* Cleaning up old procs
* It's set up to not copy datums... Unless they're in a list
* Donuts, duct tape, and detgun. D3VR coming to Early Access
* Update procs that interact with doors so they call update_state instead
* Forgot one spot, and actually might as well just force lock
* Cleaning up other things... Sigh, and kitty ears
* oops
* Getting used to how it works
* blinds
* Going back to the suit obscuring thing, so it doesn't update all the time
* Missed that from merging master
* I made this PR and forgot about it
* Fix runtimes in cards
* Make things a bit more unified
* Update update_icons.dm
* yarn, really?
* Update library_equipment.dm
* Update shieldgen.dm
* Every time Charlie merges something, I go back and see if I can improve things further
* what's this? more?
* Update misc_special.dm
* wow, paper
* Review
* More reviews
* To be sure, seems like being broken messed something sometimes
* Brought airlocks closer to how TG works to iron out some stuff
* Pizza and morgue
* Doesn't seem to hurt, tried with holodeck
* Revert "Doesn't seem to hurt, tried with holodeck"
This reverts commit 158529302b.
* Icon conflict
* Fix organ damage
* Don't ask how. Why. It's like that on prod too.
* Cutting down on things and updating from TG.
* More flexible. Just in case the thing you stuck it on didn't destroy.
* Hydro was one the things I touched earlier on, better rework it
* Reviews
* Cleaning up further, also bri'ish
* Undo a change I did, and switch over to a more recent implementation
* Update biogenerator.dm
* Rolling back to old airlocks, but with new duct taped note
* Functionally the same. I'd just rather not have the smoothing happen there
* Went over APCs again
* Fix welding helmet names in species files
* Update airlock.dm
* Update persistent_overlay.dm
* Oh, topic
This commit is contained in:
+39
-39
@@ -322,8 +322,6 @@
|
||||
status_overlays_environ[3] = image(icon, "apco2-2")
|
||||
status_overlays_environ[4] = image(icon, "apco2-3")
|
||||
|
||||
|
||||
|
||||
var/update = check_updates() //returns 0 if no need to update icons.
|
||||
// 1 if we need to update the icon_state
|
||||
// 2 if we need to update the overlays
|
||||
@@ -331,53 +329,54 @@
|
||||
return
|
||||
|
||||
if(force_update || update & 1) // Updating the icon state
|
||||
if(update_state & UPSTATE_ALLGOOD)
|
||||
icon_state = "apc0"
|
||||
else if(update_state & (UPSTATE_OPENED1|UPSTATE_OPENED2))
|
||||
var/basestate = "apc[ cell ? "2" : "1" ]"
|
||||
if(update_state & UPSTATE_OPENED1)
|
||||
if(update_state & (UPSTATE_MAINT|UPSTATE_BROKE))
|
||||
icon_state = "apcmaint" //disabled APC cannot hold cell
|
||||
else
|
||||
icon_state = basestate
|
||||
else if(update_state & UPSTATE_OPENED2)
|
||||
icon_state = "[basestate]-nocover"
|
||||
else if(update_state & UPSTATE_BROKE)
|
||||
icon_state = "apc-b"
|
||||
else if(update_state & UPSTATE_BLUESCREEN)
|
||||
icon_state = "apcemag"
|
||||
else if(update_state & UPSTATE_WIREEXP)
|
||||
icon_state = "apcewires"
|
||||
|
||||
|
||||
|
||||
..(UPDATE_ICON_STATE)
|
||||
|
||||
if(!(update_state & UPSTATE_ALLGOOD))
|
||||
if(overlays.len)
|
||||
overlays = 0
|
||||
return
|
||||
|
||||
|
||||
if(managed_overlays)
|
||||
..(UPDATE_OVERLAYS)
|
||||
return
|
||||
|
||||
if(force_update || update & 2)
|
||||
..(UPDATE_OVERLAYS)
|
||||
|
||||
if(overlays.len)
|
||||
overlays.len = 0
|
||||
/obj/machinery/power/apc/update_icon_state()
|
||||
if(update_state & UPSTATE_ALLGOOD)
|
||||
icon_state = "apc0"
|
||||
else if(update_state & (UPSTATE_OPENED1|UPSTATE_OPENED2))
|
||||
var/basestate = "apc[ cell ? "2" : "1" ]"
|
||||
if(update_state & UPSTATE_OPENED1)
|
||||
if(update_state & (UPSTATE_MAINT|UPSTATE_BROKE))
|
||||
icon_state = "apcmaint" //disabled APC cannot hold cell
|
||||
else
|
||||
icon_state = basestate
|
||||
else if(update_state & UPSTATE_OPENED2)
|
||||
icon_state = "[basestate]-nocover"
|
||||
else if(update_state & UPSTATE_BROKE)
|
||||
icon_state = "apc-b"
|
||||
else if(update_state & UPSTATE_BLUESCREEN)
|
||||
icon_state = "apcemag"
|
||||
else if(update_state & UPSTATE_WIREEXP)
|
||||
icon_state = "apcewires"
|
||||
|
||||
if(!(stat & (BROKEN|MAINT)) && update_state & UPSTATE_ALLGOOD)
|
||||
overlays += status_overlays_lock[locked+1]
|
||||
overlays += status_overlays_charging[charging+1]
|
||||
if(operating)
|
||||
overlays += status_overlays_equipment[equipment+1]
|
||||
overlays += status_overlays_lighting[lighting+1]
|
||||
overlays += status_overlays_environ[environ+1]
|
||||
/obj/machinery/power/apc/update_overlays()
|
||||
. = ..()
|
||||
if(!(update_state & UPSTATE_ALLGOOD))
|
||||
return
|
||||
|
||||
if(!(stat & (BROKEN|MAINT)) && update_state & UPSTATE_ALLGOOD)
|
||||
. += status_overlays_lock[locked+1]
|
||||
. += status_overlays_charging[charging+1]
|
||||
if(operating)
|
||||
. += status_overlays_equipment[equipment+1]
|
||||
. += status_overlays_lighting[lighting+1]
|
||||
. += status_overlays_environ[environ+1]
|
||||
|
||||
/obj/machinery/power/apc/proc/check_updates()
|
||||
|
||||
var/last_update_state = update_state
|
||||
var/last_update_overlay = update_overlay
|
||||
update_state = 0
|
||||
update_overlay = 0
|
||||
update_state = NONE
|
||||
update_overlay = NONE
|
||||
|
||||
if(cell)
|
||||
update_state |= UPSTATE_CELL_IN
|
||||
@@ -456,6 +455,7 @@
|
||||
if(!second_pass) //The first time, we just cut overlays
|
||||
addtimer(CALLBACK(src, /obj/machinery/power/apc/proc.flicker, TRUE), 1)
|
||||
cut_overlays()
|
||||
managed_overlays = null
|
||||
// APC power distruptions have a chance to propogate to other machines on its network
|
||||
for(var/obj/machinery/M in area)
|
||||
// Please don't cascade, thanks
|
||||
@@ -763,7 +763,7 @@
|
||||
user.visible_message("<span class='warning'>[user.name] removes [cell] from [src]!", "<span class='notice'>You remove [cell].</span>")
|
||||
user.put_in_hands(cell)
|
||||
cell.add_fingerprint(user)
|
||||
cell.update_icon()
|
||||
cell.update_icon(UPDATE_OVERLAYS)
|
||||
cell = null
|
||||
charging = APC_NOT_CHARGING
|
||||
update_icon()
|
||||
|
||||
+14
-12
@@ -107,15 +107,14 @@ By design, d1 is the smallest direction and d2 is the highest
|
||||
|
||||
if(level == 1 && isturf(loc))
|
||||
invisibility = i ? INVISIBILITY_MAXIMUM : 0
|
||||
updateicon()
|
||||
update_icon()
|
||||
|
||||
/obj/structure/cable/proc/updateicon()
|
||||
/obj/structure/cable/update_icon_state()
|
||||
if(invisibility)
|
||||
icon_state = "[d1]-[d2]-f"
|
||||
else
|
||||
icon_state = "[d1]-[d2]"
|
||||
|
||||
|
||||
////////////////////////////////////////////
|
||||
// Power related
|
||||
///////////////////////////////////////////
|
||||
@@ -587,19 +586,22 @@ GLOBAL_LIST_INIT(cable_coil_recipes, list (new/datum/stack_recipe/cable_restrain
|
||||
C.color = color
|
||||
return C
|
||||
|
||||
/obj/item/stack/cable_coil/update_icon()
|
||||
/obj/item/stack/cable_coil/update_name()
|
||||
. = ..()
|
||||
if(amount > 2)
|
||||
name = "cable coil"
|
||||
else
|
||||
name = "cable piece"
|
||||
|
||||
/obj/item/stack/cable_coil/update_icon_state()
|
||||
if(!color)
|
||||
color = pick(COLOR_RED, COLOR_BLUE, COLOR_GREEN, COLOR_ORANGE, COLOR_WHITE, COLOR_PINK, COLOR_YELLOW, COLOR_CYAN)
|
||||
if(amount == 1)
|
||||
icon_state = "coil1"
|
||||
name = "cable piece"
|
||||
else if(amount == 2)
|
||||
icon_state = "coil2"
|
||||
name = "cable piece"
|
||||
else
|
||||
icon_state = "coil"
|
||||
name = "cable coil"
|
||||
..()
|
||||
|
||||
/obj/item/stack/cable_coil/proc/update_wclass()
|
||||
if(amount == 1)
|
||||
@@ -686,7 +688,7 @@ GLOBAL_LIST_INIT(cable_coil_recipes, list (new/datum/stack_recipe/cable_restrain
|
||||
C.d1 = 0 //it's a O-X node cable
|
||||
C.d2 = dirn
|
||||
C.add_fingerprint(user)
|
||||
C.updateicon()
|
||||
C.update_icon()
|
||||
|
||||
//create a new powernet with the cable, if needed it will be merged later
|
||||
var/datum/powernet/PN = new()
|
||||
@@ -796,7 +798,7 @@ GLOBAL_LIST_INIT(cable_coil_recipes, list (new/datum/stack_recipe/cable_restrain
|
||||
C.d2 = nd2
|
||||
|
||||
C.add_fingerprint()
|
||||
C.updateicon()
|
||||
C.update_icon()
|
||||
|
||||
|
||||
C.mergeConnectedNetworks(C.d1) //merge the powernets...
|
||||
@@ -831,7 +833,7 @@ GLOBAL_LIST_INIT(cable_coil_recipes, list (new/datum/stack_recipe/cable_restrain
|
||||
src.amount = rand(1,2)
|
||||
pixel_x = rand(-2,2)
|
||||
pixel_y = rand(-2,2)
|
||||
update_icon()
|
||||
update_appearance(UPDATE_NAME|UPDATE_ICON_STATE)
|
||||
update_wclass()
|
||||
|
||||
/obj/item/stack/cable_coil/yellow
|
||||
@@ -877,7 +879,7 @@ GLOBAL_LIST_INIT(cable_coil_recipes, list (new/datum/stack_recipe/cable_restrain
|
||||
energy_type = /datum/robot_energy_storage/cable
|
||||
is_cyborg = TRUE
|
||||
|
||||
/obj/item/stack/cable_coil/cyborg/update_icon()
|
||||
/obj/item/stack/cable_coil/cyborg/update_icon_state()
|
||||
return // icon_state should always be a full cable
|
||||
|
||||
/obj/item/stack/cable_coil/cyborg/attack_self(mob/user)
|
||||
|
||||
+15
-16
@@ -28,7 +28,7 @@
|
||||
charge = maxcharge
|
||||
if(ratingdesc)
|
||||
desc += " This one has a power rating of [DisplayPower(maxcharge)], and you should not swallow it."
|
||||
update_icon()
|
||||
update_icon(UPDATE_OVERLAYS)
|
||||
|
||||
/obj/item/stock_parts/cell/Destroy()
|
||||
STOP_PROCESSING(SSobj, src)
|
||||
@@ -49,16 +49,16 @@
|
||||
else
|
||||
return PROCESS_KILL
|
||||
|
||||
/obj/item/stock_parts/cell/update_icon()
|
||||
overlays.Cut()
|
||||
/obj/item/stock_parts/cell/update_overlays()
|
||||
. = ..()
|
||||
if(grown_battery)
|
||||
overlays += image('icons/obj/power.dmi', "grown_wires")
|
||||
. += image('icons/obj/power.dmi', "grown_wires")
|
||||
if(charge < 0.01)
|
||||
return
|
||||
else if(charge/maxcharge >=0.995)
|
||||
overlays += "cell-o2"
|
||||
. += "cell-o2"
|
||||
else
|
||||
overlays += "cell-o1"
|
||||
. += "cell-o1"
|
||||
|
||||
/obj/item/stock_parts/cell/proc/percent() // return % charge of cell
|
||||
return 100 * charge / maxcharge
|
||||
@@ -179,7 +179,7 @@
|
||||
/obj/item/stock_parts/cell/crap/empty/New()
|
||||
..()
|
||||
charge = 0
|
||||
update_icon()
|
||||
update_icon(UPDATE_OVERLAYS)
|
||||
|
||||
/obj/item/stock_parts/cell/upgraded
|
||||
name = "upgraded power cell"
|
||||
@@ -204,7 +204,7 @@
|
||||
/obj/item/stock_parts/cell/secborg/empty/New()
|
||||
..()
|
||||
charge = 0
|
||||
update_icon()
|
||||
update_icon(UPDATE_OVERLAYS)
|
||||
|
||||
/obj/item/stock_parts/cell/hos_gun
|
||||
name = "\improper X-01 multiphase energy gun power cell"
|
||||
@@ -243,7 +243,7 @@
|
||||
/obj/item/stock_parts/cell/high/empty/New()
|
||||
..()
|
||||
charge = 0
|
||||
update_icon()
|
||||
update_icon(UPDATE_OVERLAYS)
|
||||
|
||||
/obj/item/stock_parts/cell/super
|
||||
name = "super-capacity power cell"
|
||||
@@ -257,7 +257,7 @@
|
||||
/obj/item/stock_parts/cell/super/empty/New()
|
||||
..()
|
||||
charge = 0
|
||||
update_icon()
|
||||
update_icon(UPDATE_OVERLAYS)
|
||||
|
||||
/obj/item/stock_parts/cell/hyper
|
||||
name = "hyper-capacity power cell"
|
||||
@@ -271,7 +271,7 @@
|
||||
/obj/item/stock_parts/cell/hyper/empty/New()
|
||||
..()
|
||||
charge = 0
|
||||
update_icon()
|
||||
update_icon(UPDATE_OVERLAYS)
|
||||
|
||||
/obj/item/stock_parts/cell/bluespace
|
||||
name = "bluespace power cell"
|
||||
@@ -286,7 +286,7 @@
|
||||
/obj/item/stock_parts/cell/bluespace/empty/New()
|
||||
..()
|
||||
charge = 0
|
||||
update_icon()
|
||||
update_icon(UPDATE_OVERLAYS)
|
||||
|
||||
/obj/item/stock_parts/cell/bluespace/charging
|
||||
name = "self-charging bluespace power cell"
|
||||
@@ -315,9 +315,8 @@
|
||||
rating = 12
|
||||
ratingdesc = FALSE
|
||||
|
||||
/obj/item/stock_parts/cell/infinite/abductor/update_icon()
|
||||
return
|
||||
|
||||
/obj/item/stock_parts/cell/infinite/abductor/update_overlays()
|
||||
return list()
|
||||
|
||||
/obj/item/stock_parts/cell/potato
|
||||
name = "potato battery"
|
||||
@@ -351,7 +350,7 @@
|
||||
/obj/item/stock_parts/cell/emproof/empty/New()
|
||||
..()
|
||||
charge = 0
|
||||
update_icon()
|
||||
update_icon(UPDATE_OVERLAYS)
|
||||
|
||||
/obj/item/stock_parts/cell/emproof/emp_act(severity)
|
||||
return
|
||||
|
||||
@@ -21,10 +21,11 @@
|
||||
|
||||
/obj/machinery/power/generator/Initialize(mapload)
|
||||
. = ..()
|
||||
update_desc()
|
||||
update_appearance(UPDATE_DESC)
|
||||
connect()
|
||||
|
||||
/obj/machinery/power/generator/proc/update_desc()
|
||||
/obj/machinery/power/generator/update_desc()
|
||||
. = ..()
|
||||
desc = initial(desc) + " Its cold circulator is located on the [dir2text(cold_dir)] side, and its heat circulator is located on the [dir2text(hot_dir)] side."
|
||||
|
||||
/obj/machinery/power/generator/Destroy()
|
||||
@@ -74,22 +75,21 @@
|
||||
set_light(0)
|
||||
else
|
||||
set_light(light_range_on, light_power_on)
|
||||
update_icon()
|
||||
update_icon(UPDATE_OVERLAYS)
|
||||
|
||||
|
||||
/obj/machinery/power/generator/update_icon()
|
||||
/obj/machinery/power/generator/update_overlays()
|
||||
. = ..()
|
||||
if(stat & (NOPOWER|BROKEN))
|
||||
cut_overlays()
|
||||
underlays.Cut()
|
||||
return
|
||||
else
|
||||
cut_overlays()
|
||||
if(lastgenlev != 0)
|
||||
add_overlay(mutable_appearance('icons/obj/power.dmi', "teg-op[lastgenlev]"))
|
||||
underlays += emissive_appearance(icon, "teg-op[lastgenlev]")
|
||||
|
||||
add_overlay(mutable_appearance('icons/obj/power.dmi', "teg-oc[lastcirc]"))
|
||||
underlays += emissive_appearance(icon, "teg-oc[lastcirc]")
|
||||
if(lastgenlev != 0)
|
||||
. += "teg-op[lastgenlev]"
|
||||
if(light)
|
||||
. += emissive_appearance(icon, "teg-op[lastgenlev]")
|
||||
|
||||
. += "teg-oc[lastcirc]"
|
||||
if(light)
|
||||
. += emissive_appearance(icon, "teg-oc[lastcirc]")
|
||||
|
||||
/obj/machinery/power/generator/process()
|
||||
if(stat & (NOPOWER|BROKEN))
|
||||
@@ -152,7 +152,7 @@
|
||||
if((genlev != lastgenlev) || (circ != lastcirc))
|
||||
lastgenlev = genlev
|
||||
lastcirc = circ
|
||||
update_icon()
|
||||
update_icon(UPDATE_OVERLAYS)
|
||||
|
||||
updateDialog()
|
||||
|
||||
@@ -188,7 +188,7 @@
|
||||
hot_dir = SOUTH
|
||||
connect()
|
||||
to_chat(user, "<span class='notice'>You reverse the generator's circulator settings. The cold circulator is now on the [dir2text(cold_dir)] side, and the heat circulator is now on the [dir2text(hot_dir)] side.</span>")
|
||||
update_desc()
|
||||
update_appearance(UPDATE_DESC)
|
||||
|
||||
/obj/machinery/power/generator/wrench_act(mob/user, obj/item/I)
|
||||
. = TRUE
|
||||
|
||||
@@ -250,15 +250,14 @@ GLOBAL_LIST_EMPTY(gravity_generators)
|
||||
else
|
||||
return "off"
|
||||
|
||||
/obj/machinery/gravity_generator/main/update_icon()
|
||||
..()
|
||||
cut_overlays()
|
||||
/obj/machinery/gravity_generator/main/update_overlays()
|
||||
. = ..()
|
||||
if(get_status() != "generator_welding" && get_status() != "generator_plasteel")
|
||||
add_overlay("generator_part")
|
||||
. += "generator_part"
|
||||
if(get_status() == "off")
|
||||
return
|
||||
add_overlay("[get_status()]")
|
||||
add_overlay("[overlay_state]")
|
||||
. += "[get_status()]"
|
||||
. += "[overlay_state]"
|
||||
|
||||
/**
|
||||
* Set the charging state based on external power and the breaker state.
|
||||
|
||||
@@ -279,8 +279,7 @@
|
||||
// A.update_lights()
|
||||
return ..()
|
||||
|
||||
/obj/machinery/light/update_icon()
|
||||
|
||||
/obj/machinery/light/update_icon_state()
|
||||
switch(status) // set icon_states
|
||||
if(LIGHT_OK)
|
||||
if(emergency_mode)
|
||||
@@ -296,7 +295,6 @@
|
||||
if(LIGHT_BROKEN)
|
||||
icon_state = "[base_state]-broken"
|
||||
on = FALSE
|
||||
return
|
||||
|
||||
/**
|
||||
* Updates the light's 'on' state and power consumption based on [/obj/machinery/light/var/on].
|
||||
|
||||
@@ -30,7 +30,7 @@
|
||||
/obj/machinery/power/port_gen/proc/handleInactive()
|
||||
return
|
||||
|
||||
/obj/machinery/power/port_gen/update_icon()
|
||||
/obj/machinery/power/port_gen/update_icon_state()
|
||||
icon_state = "[base_icon]_[active]"
|
||||
|
||||
/obj/machinery/power/port_gen/process()
|
||||
|
||||
@@ -97,13 +97,12 @@
|
||||
QDEL_NULL(sparks)
|
||||
return ..()
|
||||
|
||||
/obj/machinery/power/emitter/update_icon()
|
||||
/obj/machinery/power/emitter/update_icon_state()
|
||||
if(active && powernet && avail(active_power_usage))
|
||||
icon_state = "emitter_+a"
|
||||
else
|
||||
icon_state = "emitter"
|
||||
|
||||
|
||||
/obj/machinery/power/emitter/emag_act(mob/living/user)
|
||||
if(!emagged)
|
||||
locked = FALSE
|
||||
|
||||
@@ -40,15 +40,14 @@ field_generator power level display
|
||||
var/list/obj/machinery/field/generator/connected_gens
|
||||
var/clean_up = FALSE
|
||||
|
||||
/obj/machinery/field/generator/update_icon()
|
||||
overlays.Cut()
|
||||
/obj/machinery/field/generator/update_overlays()
|
||||
. = ..()
|
||||
if(warming_up)
|
||||
overlays += "+a[warming_up]"
|
||||
. += "+a[warming_up]"
|
||||
if(fields.len)
|
||||
overlays += "+on"
|
||||
. += "+on"
|
||||
if(power_level)
|
||||
overlays += "+p[power_level]"
|
||||
|
||||
. += "+p[power_level]"
|
||||
|
||||
/obj/machinery/field/generator/Initialize(mapload)
|
||||
. = ..()
|
||||
|
||||
@@ -87,11 +87,6 @@ So, hopefully this is helpful if any more icons are to be added/changed/wonderin
|
||||
icon_state = "end_cap"
|
||||
reference = "end_cap"
|
||||
|
||||
/obj/structure/particle_accelerator/update_icon()
|
||||
..()
|
||||
return
|
||||
|
||||
|
||||
/obj/structure/particle_accelerator/verb/rotate()
|
||||
set name = "Rotate Clockwise"
|
||||
set category = "Object"
|
||||
@@ -155,7 +150,7 @@ So, hopefully this is helpful if any more icons are to be added/changed/wonderin
|
||||
if(prob(50))
|
||||
qdel(src)
|
||||
|
||||
/obj/structure/particle_accelerator/update_icon()
|
||||
/obj/structure/particle_accelerator/update_icon_state()
|
||||
switch(construction_state)
|
||||
if(0,1)
|
||||
icon_state="[reference]"
|
||||
@@ -166,7 +161,6 @@ So, hopefully this is helpful if any more icons are to be added/changed/wonderin
|
||||
icon_state="[reference]p[strength]"
|
||||
else
|
||||
icon_state="[reference]c"
|
||||
return
|
||||
|
||||
/obj/structure/particle_accelerator/proc/update_state()
|
||||
if(master)
|
||||
@@ -292,9 +286,6 @@ So, hopefully this is helpful if any more icons are to be added/changed/wonderin
|
||||
dir = turn(dir, 90)
|
||||
return 1
|
||||
|
||||
/obj/machinery/particle_accelerator/update_icon()
|
||||
return
|
||||
|
||||
/obj/machinery/particle_accelerator/attackby(obj/item/W, mob/user, params)
|
||||
if(!iscoil(W))
|
||||
return ..()
|
||||
|
||||
@@ -4,7 +4,3 @@
|
||||
icon = 'icons/obj/machines/particle_accelerator.dmi'
|
||||
icon_state = "fuel_chamber"
|
||||
reference = "fuel_chamber"
|
||||
|
||||
/obj/structure/particle_accelerator/fuel_chamber/update_icon()
|
||||
..()
|
||||
return
|
||||
|
||||
@@ -64,7 +64,7 @@
|
||||
|
||||
return
|
||||
|
||||
/obj/machinery/particle_accelerator/control_box/update_icon()
|
||||
/obj/machinery/particle_accelerator/control_box/update_icon_state()
|
||||
if(active)
|
||||
icon_state = "[reference]p[strength]"
|
||||
else
|
||||
@@ -83,7 +83,6 @@
|
||||
icon_state = "[reference]w"
|
||||
else
|
||||
icon_state = "[reference]c"
|
||||
return
|
||||
|
||||
/obj/machinery/particle_accelerator/control_box/Topic(href, href_list)
|
||||
if(..(href, href_list))
|
||||
|
||||
@@ -18,10 +18,6 @@
|
||||
icon_state = "emitter_right"
|
||||
reference = "emitter_right"
|
||||
|
||||
/obj/structure/particle_accelerator/particle_emitter/update_icon()
|
||||
..()
|
||||
return
|
||||
|
||||
/obj/structure/particle_accelerator/particle_emitter/proc/set_delay(delay)
|
||||
if(delay && delay >= 0)
|
||||
fire_delay = delay
|
||||
|
||||
@@ -83,17 +83,17 @@
|
||||
C += PC.maxcharge
|
||||
capacity = C / (15000) * 1e6
|
||||
|
||||
/obj/machinery/power/smes/update_icon()
|
||||
cut_overlays()
|
||||
/obj/machinery/power/smes/update_overlays()
|
||||
. = ..()
|
||||
if(stat & BROKEN)
|
||||
return
|
||||
|
||||
add_overlay("smes-op[outputting ? 1 : 0]")
|
||||
add_overlay("smes-oc[inputting ? 1 : 0]")
|
||||
. += "smes-op[outputting ? 1 : 0]"
|
||||
. += "smes-oc[inputting ? 1 : 0]"
|
||||
|
||||
var/clevel = chargedisplay()
|
||||
if(clevel > 0)
|
||||
add_overlay("smes-og[clevel]")
|
||||
var/charge_level = chargedisplay()
|
||||
if(charge_level > 0)
|
||||
. += "smes-og[charge_level]"
|
||||
|
||||
/obj/machinery/power/smes/attackby(obj/item/I, mob/user, params)
|
||||
//opening using screwdriver
|
||||
|
||||
+10
-12
@@ -93,15 +93,13 @@
|
||||
new /obj/item/shard(src.loc)
|
||||
qdel(src)
|
||||
|
||||
/obj/machinery/power/solar/update_icon()
|
||||
..()
|
||||
overlays.Cut()
|
||||
/obj/machinery/power/solar/update_overlays()
|
||||
. = ..()
|
||||
if(stat & BROKEN)
|
||||
overlays += image('icons/goonstation/objects/power.dmi', icon_state = "solar_panel-b", layer = FLY_LAYER)
|
||||
. += image('icons/goonstation/objects/power.dmi', icon_state = "solar_panel-b", layer = FLY_LAYER)
|
||||
else
|
||||
overlays += image('icons/goonstation/objects/power.dmi', icon_state = "solar_panel", layer = FLY_LAYER)
|
||||
. += image('icons/goonstation/objects/power.dmi', icon_state = "solar_panel", layer = FLY_LAYER)
|
||||
set_angle(adir)
|
||||
return
|
||||
|
||||
//calculates the fraction of the sunlight that the panel recieves
|
||||
/obj/machinery/power/solar/proc/update_solar_exposure()
|
||||
@@ -340,16 +338,16 @@
|
||||
set_panels(cdir)
|
||||
updateDialog()
|
||||
|
||||
/obj/machinery/power/solar_control/update_icon()
|
||||
overlays.Cut()
|
||||
/obj/machinery/power/solar_control/update_overlays()
|
||||
. = ..()
|
||||
if(stat & NOPOWER)
|
||||
overlays += "[icon_keyboard]_off"
|
||||
. += "[icon_keyboard]_off"
|
||||
return
|
||||
overlays += icon_keyboard
|
||||
. += icon_keyboard
|
||||
if(stat & BROKEN)
|
||||
overlays += "[icon_state]_broken"
|
||||
. += "[icon_state]_broken"
|
||||
else
|
||||
overlays += icon_screen
|
||||
. += icon_screen
|
||||
|
||||
/obj/machinery/power/solar_control/attack_ai(mob/user as mob)
|
||||
add_hiddenprint(user)
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
if(anchored)
|
||||
connect_to_network()
|
||||
|
||||
/obj/machinery/power/treadmill/update_icon()
|
||||
/obj/machinery/power/treadmill/update_icon_state()
|
||||
icon_state = speed ? "conveyor-1" : "conveyor0"
|
||||
|
||||
/obj/machinery/power/treadmill/Crossed(mob/living/M, oldloc)
|
||||
@@ -171,13 +171,13 @@
|
||||
. = ..()
|
||||
. += "The display reads:<div style='text-align: center'>[line1]<br>[line2]</div>"
|
||||
|
||||
/obj/machinery/treadmill_monitor/update_icon()
|
||||
overlays.Cut()
|
||||
/obj/machinery/treadmill_monitor/update_overlays()
|
||||
. = ..()
|
||||
if(stat & NOPOWER || !total_joules || !on)
|
||||
line1 = ""
|
||||
line2 = ""
|
||||
else if(stat & BROKEN)
|
||||
overlays += image('icons/obj/status_display.dmi', icon_state = "ai_bsod")
|
||||
. += image('icons/obj/status_display.dmi', icon_state = "ai_bsod")
|
||||
line1 = "A@#$A"
|
||||
line2 = "729%!"
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user