I don't know about that error (sounds strange to me), but for checking things with passable and solid blocks you can use following keywords in your entity function:
in_passable (inside passable block)
on_passable (standing on passable block)
Those temporary variables are set after each c_move and c_trace automatically.
For more details check the manual pages of those commands.
So, you do not recommend using regions?