Zoom in and can pan the camera Orthographic??

I use this script to zoom in and out 2DCamera, but when I zoom I can not move image by one finger how could I did with it…

using UnityEngine;
using System.Collections;
//Creating by Neodrop
//neodrop@unity3d.ru
[RequireComponent(typeof(Camera))]

public class Zoomer_2DCam : MonoBehaviour {



     public float stepPerSecond = 1f, orthoMin = 3f, orthoMax = 6f;
     float lastDistance = 0f;

    void FixedUpdate()
    {
        if (iPhoneInput.touchCount != 2)
        {
             lastDistance = 0;
             return;
        }

        if (iPhoneInput.touches[0].phase != iPhoneTouchPhase.Moved && iPhoneInput.touches[1].phase != iPhoneTouchPhase.Moved)
        {
           lastDistance = 0;
           return;
        }

        iPhoneTouch[] touch = iPhoneInput.touches;

        float distance = Vector2.Distance(touch[0].position, touch[1].position);

        if (distance == lastDistance) return;

       float touchDistance = (touch[1].position - touch[0].position).magnitude;
       float lastTouchDistance = ((touch[1].position - touch[1].deltaPosition) - (touch[0].position - touch[0].deltaPosition)).magnitude;
       float deltaPinch = touchDistance - lastTouchDistance;

      camera.orthographicSize += deltaPinch * stepPerSecond * Time.deltaTime;

      if (camera.orthographicSize < orthoMin) camera.orthographicSize = orthoMin;
      else if (camera.orthographicSize > orthoMax) camera.orthographicSize = orthoMax;


     lastDistance = distance;
    }

}

thx for your comment!!!

this code

if (iPhoneInput.touchCount != 2)

leads to your code for handling two finger touches:

so, that’s your zooming functions.

You would need to write new code for the case of one-finger touches

   if ( count == 1 )
     {
     you write lots of codes here
     you write lots of codes here
     you write lots of codes here
     }

it’s worth noting that this is really very hard to do well. Here’s a very long answer about just one aspect of the issue: