Objects blocking player in view

So after setting up my scene/moment i have buildings that block the camera and make make it to where i cant move or see my player.

I have a few ideas on the issue (like create a hideobjects class to call on update in playercontroller) but am having trouble figuring it out? Any help on how to implement making objects hide when they block the camera?

Or would it be simpler to use SetActive() on the GameObject? I want to be able to click through when the object is hidden.

There are a number of ways to achieve this. One of the easiest ways is to use a CinemachineCollider on your virtual camera. Place all objects that you want the CinemachineCollider to adjust the camera for on their own layer, and set the Collider to react to that layer.

In addition, with a game style like this, where the camera’s direction is fixed, scene design becomes essential. On a fixed direction set, many things can be treated like movie sets. For example, while you’re watching your favorite TV show, the set generally doesn’t have a wall on one side of the set. It’s best to put taller buildings on the top of the scene and shorter buildings that don’t block as much of the scene.

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.

Privacy & Terms