|
Post by popeyzzz on Dec 21, 2022 7:15:09 GMT
Hey, great asset! I'm looking to achieve a similar camera affect seen here: youtu.be/O_VsBfZaz20?t=550When the camera zooms, I'd like to change the rotation of the camera. For example, when the camera is zoomed in at the "Max Zoom In Amount", I'd like the camera to have a rotation of -45 degrees. when the camera is zoomed out at the "Max Zoom Out Amount", I'd like the camera to have a rotation of -10 degrees. I'd like this this rotation to have the same smoothness just like the zoom. How do I do this using your Pan & Zoom extension?
|
|
|
Post by popeyzzz on Jan 18, 2023 7:51:55 GMT
|
|
|
Post by Luís Pedro Fonseca on Jan 19, 2023 12:02:32 GMT
Hi popeyzzz, sorry for the delay but I completely missed your first message. Unfortunately ProCamera2D doesn't currently support camera rotations, because if you rotate it, it then stops being a 2D camera. You can get away you manually rotating it a few degrees, but be aware that the further the camera is from its "straight" rotation, the more its calculations will deviate. Let me know if this makes sense and how else could I help. Cheers
|
|
|
Post by popeyzzz on Jan 20, 2023 6:31:37 GMT
Thanks for the reply! What calculations will deviate? Do you have any recommendations on how to implement this with good performance? How do I make zoom also trigger camera rotation? When I rotate the camera, I'm also rotating buildings on the map to face the camera.
|
|
|
Post by Luís Pedro Fonseca on Jan 21, 2023 17:09:24 GMT
Calculations like your targets center, the boundaries, etc. I don't have any recommendations on how to achieve this since it's not supported. I think you'd be better off with something like Cinemachine. Sorry for the inconvenience.
|
|