mirror of
https://github.com/vgstation-coders/vgstation13.git
synced 2025-12-10 18:32:03 +00:00
LIGHTING IS BACK.
AND A SHITLOAD FASTER. SANIC.
This commit is contained in:
@@ -22,7 +22,7 @@
|
||||
|
||||
var/max_luminosity = 8 // Now varies based on power.
|
||||
|
||||
l_color = "#ffcc00"
|
||||
light_color = LIGHT_COLOR_YELLOW
|
||||
|
||||
// What it's referred to in the alerts
|
||||
var/short_name = "Crystal"
|
||||
@@ -285,8 +285,10 @@
|
||||
|
||||
power -= (power/500)**3
|
||||
|
||||
var/light_value = Clamp(round(Clamp(power / max_power, 0, 1) * max_luminosity), 0, max_luminosity)
|
||||
|
||||
// Lighting based on power output.
|
||||
SetLuminosity(Clamp(round(Clamp(power/max_power,0,1)*max_luminosity),0,max_luminosity))
|
||||
set_light(light_value, light_value / 2)
|
||||
|
||||
return 1
|
||||
|
||||
|
||||
Reference in New Issue
Block a user