Removing an IC light turns the light off (#8306)

This commit is contained in:
mikomyazaki
2020-02-19 01:25:41 -03:00
committed by GitHub
parent 9820143f39
commit 5ad6486c5c
2 changed files with 11 additions and 0 deletions
@@ -83,6 +83,11 @@
assembly.set_light(0)
power_draw_idle = light_toggled ? light_brightness * 2 : 0
/obj/item/integrated_circuit/output/light/disconnect_all()
..()
light_toggled = FALSE
update_lighting()
/obj/item/integrated_circuit/output/light/advanced/update_lighting()
var/new_color = get_pin_data(IC_INPUT, 1)
var/brightness = get_pin_data(IC_INPUT, 2)