Merge pull request #20580 from ChangelingRain/lightenlightdrainamount

Clockcult powerdraining is more likely to cause lights to burn out
This commit is contained in:
oranges
2016-09-24 19:49:38 +12:00
committed by GitHub
2 changed files with 11 additions and 5 deletions
+9 -5
View File
@@ -232,11 +232,8 @@
if(status == LIGHT_OK && trigger)
explode()
else if( prob( min(60, switchcount*switchcount*0.01) ) )
if(status == LIGHT_OK && trigger)
status = LIGHT_BURNED
icon_state = "[base_state]-burned"
on = 0
SetLuminosity(0)
if(trigger)
burn_out()
else
use_power = 2
SetLuminosity(brightness)
@@ -254,6 +251,13 @@
removeStaticPower(static_power_used, STATIC_LIGHT)
/obj/machinery/light/proc/burn_out()
if(status == LIGHT_OK)
status = LIGHT_BURNED
icon_state = "[base_state]-burned"
on = 0
SetLuminosity(0)
// attempt to set the light's on/off status
// will not switch on if broken/burned/empty
/obj/machinery/light/proc/seton(s)