Android unity, have the left side of the screen act as Fire1 and the right side act as Fire2.

Hello, I am attempting to set up my phone to have the left half activate a force script on the left flipper and the right side activate the script for the right flipper. In essence I am wanting the left side to act as Fire1 and the right side act as Fire2 when ever they are touched. Right now, one finger touching the screen is acting as Fire1 and when I use two fingers it acts as Fire2. I have attempted to use UI buttons, but I cannot get them to work properly. Any help is greatly appreciated.

All you need to do is use the touch.deltaposition which is a vector2 and check the X is greater then divide the screen width in half and check to see if it’s greater than that. If is less than that then it’s left if it’s greater then it’s right.

Thank you for replying! I was able to find a tutorial that suggested this as well and used ray casting attached to the camera that determines the position of a touch. Thanks again.

You can do something like on this tutorial Live Training 8th December 2014 - Mobile Development: Space Shooter to Mobile - YouTube