Camera in Interiors (895895)

Hey there,
Couldn’t find any similar thread, so I’m asking. I just want to insist on the fact that I’m a pure newbie.

I was wondering if there were any (rather easy?) workarounds for changing or make the camera understand the collisions with a building’s interior walls and such when the player enters it?

By default we can’t see anything when the player enters a building with an interior. I’ve tried the Unity-Object-Fade scripts (GitHub - jhutchines/Unity-Object-Fade: Simple scripts to make objects that block the cameras view of the player transparent. · GitHub) but I’ve no real idea how to set this time, especially knowing that the interior(s) may have multiple levels.

Any idea?
Thanks, and sorry if this isn’t the right part of the forums.

EDIT:
Sorry for the cross-post, I expected to be able to self-delete the other thread. Woopsies.

You should look into Cinemachine. It allows you to set up collision handling for the camera, specifically useful for 3rd person cameras.

I think the free 3rd Person Character Controller asset in the store (made by unity) shows this in action.

Hey CodeSmile,
Thanks for the reply.

I should’ve specified the game’s supposed to be in an Isometric view, which makes Cinemachine… maybe not adequate, or perhaps I set the parameters wrongly. :confused:
I’ll take a look at that free 3rd Person Character Controller asset.

Thanks again!

I think cinemachine can pretty much do it all… what CodeSmile is referring to is an ability to move the camera in a way to keep objects out of a sub-area of the view. Did you look up the cinemachine docs for collision handling?

But if you want to roll your own “roof remover” the fact that your game is isometric probably simplifies your problem space into layers of floors that could block. There’s lots of tutorials for that sorta camera work.

Could be a great work-around aswell.
I stumbled upon different scripts that let the camera see the player and defined objects through walls without too much issue. I’ll still try that aswell!

Thanks!