MultiTouch on Android

I am trying to use two controls. one is button(GUITexture) to move forward and other for turning.
The problem is when I am moving forward its not sensing the turning button and vice-versa.
while turning its not moving forward.

Is there any multiTouch issue??

yup I got the solution…

M using

Input.getTouch(0)

for one control and

input.getTouch(1)

for another control…

If you want to access both the touches you can use for loop to access.

if(Input.touchCount>0)
    for(int i=0; i<Input.touchCount; i++)
    {
       print(Input.getTouch(i).position);
    }
  1. For moving forward i hav a speedPad (GUITexture) and code for moving

    if(speedPad.HitTest(Input.GetTouch(0).position) && (Input.GetTouch(0).phase==TouchPhase.Stationary || Input.GetTouch(0).phase==TouchPhase.Moved))

     	{
     		movevector = speed * Input.touchCount;
     	}
    
  2. for moving left right i hav onGUI()

savedMatrix = GUI.matrix;

	if(Input.GetTouch(0).position.x > 30f && Input.GetTouch(0).position.x < steering.width+80f && Input.GetTouch(0).position.y > 0 && Input.GetTouch(0).position.y < steeringPos.y+steering.height)

	{
		dx=Input.GetTouch(0).position.x-centre.x;
		dy=Input.GetTouch(0).position.y-(780-centre.y);
		steerAngleRad=Mathf.Atan2(dy,dx);
		steerAngleDeg=-steerAngleRad*Mathf.Rad2Deg;
		GUIUtility.RotateAroundPivot(steerAngleDeg-180,centre);
	}
	GUI.DrawTexture(new Rect(50,480, steering.width, steering.height), steering);
	GUI.matrix = savedMatrix;

http://www.rozgo.com/blog/?p=162#post-162 maybe this example help you.

You can either use just the Input.Touch api’s, or why not use the dual joystick prefab in Standard Assets(mobile)? it does all that for you.