If I were to attack this one, I'd probably write a spell that fires straight up from an invisible Activator spawned over the player's head. It would have no magnitude and an area of 5000. In that spell's ActiveMagicEffect script, I'd set a Global that can tell other scripts we're under a roof.
If the spell hits a surface on it's way up, the player is under a roof (or
something that blocks the sky over their head). The tremendous area of effect means the script will always run at least once, even if it's only because the player is an affected target. If the player is in the open, the projectile never impacts, so the script doesn't get run, so the Global doesn't get set.
The downside of this is that, if the player was under a roof but is now standing in the open, the script doesn't get run at all, so whatever script fires this checking spell will need to reset the global, fire the check-for-roof spell, wait a moment, then check the value of the Global.
A bit cumbersome but it should be fairly reliable.
Incidentally, I'm assuming you want to literally check if the player is under a roof, not just to see if we're in an interior cell. If this is not the case, ignore everything I just typed and http://www.creationkit.com/IsInInterior_-_ObjectReference.