Page 1 of 1

How to have DS choose a camera that does not collide with a wall?

Posted: Sat Jan 18, 2020 4:42 am
by Juddruss
Say I have defined several camera angles that DS will choose from randomly. How do I make sure it picks the one that does not see through a wall? My game has a lot of indoor spaces and some cameras end up being behind a wall or so close to them that you end up seeing through the walls

Re: How to have DS choose a camera that does not collide with a wall?

Posted: Sat Jan 18, 2020 9:04 am
by Tony Li
Hi,

That's a bit beyond what the Camera() sequencer command does. You could write a custom sequencer command to use in place of Camera(), or you could try Cinemachine (see Timeline & Cinemachine for integration details). Cinemachine has collision detection.