_cockpit mesh

Added a _cockpit mesh to my 2003 TrailBlazer this morning, but looking for any input as this is my first implementation of it. My intention was to keep water and stuff from getting inside the cabin, and as you can see in the first screenshot it does work fine when using the interior/cockpit view. Is there a way to prevent water intrusion from the EXTERIOR views?
0_1541946648596_20181111101426_1.jpg
0_1541946666574_20181111101439_1.jpg

@mexican_420 said in _cockpit mesh:

@Mexican_420 "Is there a way to prevent water intrusion from the EXTERIOR views?"
Don't drive in the river..:smiling_cat_face_with_open_mouth:
_
_Sorry, I couldn't resist... the pic with the water up to the windows is great. i hope you get it working with the exterior view.
_Rufus

how would one go about making such a "cockpit mesh" is it like a cdt? or is it just the whole interior in one mesh?

@hydrowasul
Make a mesh that roughly (or exactly) matches the interior of the vehicle, and ensure that said mesh's normals face INWARD. Name it "_cockpit" (the game engine will not render this mesh) and when you're in the cab view, anything inside the mesh stays clean and dry (as shown in my first screenshot above). @Forces suggested a 2nd mesh (duplicate of my original _cockpit mesh) but with the normals facing OUTWARDS, but that causes my windows to be rendered opaque instead of transparent, so I was unable to see whether there was water inside the cabin from outside view. Might try making the 2nd _cockpit mesh transparent and see if that works.

so basically a very low poly version of the interior will do? i'm asking because i have multiple meshes (seats, dashboard etc.) and if i combine them into one it might be over the poly limit

edit: what if you give the 2nd mesh (outward facing one) a texture with a completely transparent alpha channel? that might cause problems with the alpha transparency of the windows though, not sure

last edited by hydrowasul

@hydrowasul
Yeah, it doesn't have to be super hipoly. Even a basic box will work, but only the space inside the box will stay dry, so I just recommended cloning the interior so that the boundaries between the wet and the dry would match as close as possible and you wouldn't end up with some parts of the interior staying dry while other parts get wet/dirty.

oh yeah, inside the box stays dry, that makes sense... i guess it works the same way for the _windshield mesh then?
when i tried to figure that one out, the texture wouldn't show up ingame unless i used the default one of the uaz

@hydrowasul
Not sure, haven't played around with the _windshield mesh. I only messed with the _cockpit mesh to try and keep a dry cabin visible through the rear window from the chase cam.