Beginner: How to manage object intersections

Hi

New to unity and working way through tutorials etc. Had some useful help here already (thanks). Trying to run before I can walk, of course;

I’ve got a building (a box) that I can walk around and step inside. It has a mesh collider so I can’t walk through walls.

I’ve figured out trees and have some placed near my building.

Now, when I place my trees near by building, the leaves go through the building walls and are visible from inside.

What do I need to do to my building to prevent those leaves coming through?

Thanks

Peter

thats a modelling thing, if theyre poking thru, you need to delete some polygons…or move the tree back…
AC

OK, Thanks

If I understand your question, the only way to prevent this would be to remodel the tree so it doesn’t extend through a wall, move it further away from the outside of the wall, write some code that turns off the tree layer as the player enters the building or have your game change scenes as the player passes through a door to the interior of your building.

HTH