Merge branch 'pai_light' of https://github.com/Tayyyyyyy/Paradise into pai_light

Conflicts:
	code/game/gamemodes/shadowling/shadowling_abilities.dm
	code/game/objects/items/devices/flashlight.dm
	code/modules/mob/living/carbon/human/human.dm
	code/modules/mob/living/living.dm
	code/modules/mob/living/silicon/robot/robot.dm

 Changes to be committed:
	modified:   code/game/gamemodes/shadowling/shadowling_abilities.dm
	modified:   code/game/machinery/computer/computer.dm
	modified:   code/game/machinery/floodlight.dm
	modified:   code/game/objects/items/devices/flashlight.dm
	modified:   code/game/objects/items/devices/paicard.dm
	modified:   code/modules/clothing/head/hardhat.dm
	modified:   code/modules/clothing/spacesuits/hardsuit.dm
	modified:   code/modules/clothing/spacesuits/plasmamen.dm
	modified:   code/modules/lighting/lighting_atom.dm
	modified:   code/modules/mob/living/carbon/human/human.dm
	modified:   code/modules/mob/living/living.dm
	modified:   code/modules/mob/living/silicon/pai/pai.dm
	modified:   code/modules/mob/living/silicon/pai/software_modules.dm
	modified:   code/modules/mob/living/silicon/robot/robot.dm
	modified:   code/modules/pda/PDA.dm
	modified:   code/modules/power/lighting.dm
	modified:   code/modules/projectiles/gun.dm
This commit is contained in:
taukausanake
2019-02-02 22:53:46 -06:00
17 changed files with 109 additions and 82 deletions
+11 -7
View File
@@ -137,7 +137,7 @@
idle_power_usage = 2
active_power_usage = 20
power_channel = LIGHT //Lights are calc'd via area so they dont need to be in the machine list
var/on = 0 // 1 if on, 0 if off
var/on = FALSE // 1 if on, 0 if off
var/on_gs = 0
var/static_power_used = 0
var/brightness_range = 8 // luminosity when on, also used in power calculation
@@ -159,7 +159,6 @@
var/nightshift_light_power = 0.45
var/nightshift_light_color = "#FFDDCC"
// the smaller bulb light fixture
/obj/machinery/light/small
@@ -213,7 +212,7 @@
/obj/machinery/light/Destroy()
var/area/A = get_area(src)
if(A)
on = 0
on = FALSE
// A.update_lights()
return ..()
@@ -224,13 +223,13 @@
icon_state = "[base_state][on]"
if(LIGHT_EMPTY)
icon_state = "[base_state]-empty"
on = 0
on = FALSE
if(LIGHT_BURNED)
icon_state = "[base_state]-burned"
on = 0
on = FALSE
if(LIGHT_BROKEN)
icon_state = "[base_state]-broken"
on = 0
on = FALSE
return
// update the icon_state and luminosity of the light depending on its state
@@ -255,7 +254,7 @@
if(status == LIGHT_OK && trigger)
status = LIGHT_BURNED
icon_state = "[base_state]-burned"
on = 0
on = FALSE
set_light(0)
else
use_power = ACTIVE_POWER_USE
@@ -730,3 +729,8 @@
if(limb)
limb.droplimb(0, DROPLIMB_BURN)
return FIRELOSS
/obj/machinery/light/extinguish_light()
on = FALSE
visible_message("<span class='danger'>[src] flickers and falls dark.</span>")
update(0)