added luminosity detector, fixed bug with for loop if statement checking for _