I implemented a rough version of this using a table of all light positions + sizes then determining if the player is overlapping with any of the light sources. I am not happy with this solution and am still looking for a way to read a pixel color directly.
I was looking at this forum post: How to load a texture from a matrix of colors - Questions - Defold game engine forum
Is there a way I can turn a render target such as “self.light_rt” into a texture then read the color value?