I am creating a drag system that needs to be mobile friendly. How can I prevent camera from rotating when player drags item across their screen?
I also want the camera to still follow the player as they move and ideally the player can still move the camera with a second finger, not the first finger that’s dragging the item.
you should be able to just set the cameratype to scriptable and revert it once they’ve dropped the item to prevent the camera from moving
edit: wow i can’t believe i just totally missed the second part my first read-thru. my answer is kinda redundant though because spoodr’s reply covers pretty much everything perfectly lol
Now for camera to rotate with second finger, I assume you can use the TouchRotate event of UserInputService (I am not that aware of mobile events). This event fires when two fingers attempt to rotate on screen. Since your one finger is already dragging , I believe this should work. You could try getting the delta of second finger to rotate the variable angle.