Camera-movement within another camera
Hi, I am trying to create a different camera for dialouges. Its attached to the player object so that it moves with him. the problem i have is that when the player stands close to the edge of a room, the dialogcamera would render outside the room. is there a way to restrict camera-movement only within another camera (or a specified x and y value, using collision detectors or whatever).
btw the main camera has a fixed place and the background is a 2d drawn image.
thanks :D
Answer by JigneshKoradiya · Apr 07, 2016 at 06:33 AM
1)create another camera and give name it UI cam and make it depth only camera from inspector and set its depth to 3 from inspector and set that camera to far from your room and also put dialog in the front of that new UI camera
2) other option is you can assign layer to dialog box for example create new layer dialog and give it to dialogbox and than in ui camera you have to set cullingmast to dialogbox and in maincamera you have to unchecked the dialogbox from the culling mask option
Your answer
Follow this Question
Related Questions
Making a Smooth camera zoom with transform.Translate 1 Answer
Editor Camera Issue 0 Answers
I need help with my third person camera raycast 0 Answers
How to lower and raise height the camera height 0 Answers
Implementing Json for dialogue system? 0 Answers