Bugfix: AI Camera light toggle

Fixes #3676

Before:  Toggling would get stuck where it wouldn't toggle the camera until you reset your view.

After:  Camera light toggles, you have to toggle off before turning on a new camera light though.
This commit is contained in:
Ccomp5950
2014-02-11 03:20:22 -06:00
parent a543b046fe
commit 62b70bb827
+4 -3
View File
@@ -666,10 +666,11 @@ var/list/ai_list = list()
camera_light_on = !camera_light_on
src << "Camera lights [camera_light_on ? "activated" : "deactivated"]."
if(!camera_light_on)
if(src.current)
src.current.SetLuminosity(0)
if(current)
current.SetLuminosity(0)
current = null
else
src.lightNearbyCamera()
lightNearbyCamera()