Now that I look again it's pretty unclear, but vehicle::is_inside() means
fully enclosed, and it degrades as you'd expect as parts of the car get
damaged.  It means there's a roof over your head, and that there are either
roof or board tiles completely surrounding you.
On May 7, 2013 12:57 PM, "indigochill" <notifications@github.com> wrote:

> In field.cpp:
>
> > @@ -1024,3 +1024,32 @@ bool vector_has(std::vector <item> vec, itype_id type)
> >   }
> >   return false;
> >  }
> > +
> > +void map::field_effect(int x, int y, game *g) //Applies effect of field immediately
> > +{
> > + field *cur = &field_at(x, y);
> > + switch (cur->type) {                        //Can add independent code for different types of fields to apply different effects
> > +  case fd_rubble:
> > +   int fdmon = g->mon_at(x, y);              //The index of the monster at (x,y), or -1 if there isn't one
> > +   int fdnpc = g->npc_at(x, y);              //The index of the NPC at (x,y), or -1 if there isn't one
> > +   if (g->u.posx == x && g->u.posy == y) {
> > +    g->u.hurtall(10);                         //Avoiding disease system for the moment, since I was having trouble with it.
>
> This bit? <https://gist.github.com/indigochill/b96315ee0f7a46fb8f43>
>
> It looks (of course, I could be mistaken) like it would only checks if the
> player is "inside" the vehicle, or in other words not on an external
> (outer) part. This would protect from ground-based effects like acid, but
> not from things falling from above, unless I'm misunderstanding.
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/TheDarklingWolf/Cataclysm-DDA/pull/856/files#r4118969>
> .
>