Perhaps you can check for the amount of light hitting the object and adjust the opacity of your object based on that value.
I'm not sure of the specifics but it could be something like:
self.set_opacity(0 + self.lightvalue)
0 making the sprite invisible and the self.lightvalue being the value of light hitting the sprite (I'm not sure what the name for this value is actually called). So that when self.lightvalue is 0 (No light), the opacity is 0 + 0 which would make the sprite invisible.
Sorry for not having more specifics to help you with, but hopefully that helps some!