using UnityEngine;
using System.Collections;
/// <summary>
/// Found in
/// http://unity3d.com/pt/learn/tutorials/modules/beginner/platform-specific/pinch-zoom
/// Contains both perspective and orthographic stuff, in this 2D game we'll
/// be using only the orthographic one
/// </summary>
public class CameraPinchToZoom : MonoBehaviour
{
public float perspectiveZoomSpeed = 0.5f; // The rate of change of the field of view in perspective mode.
public float orthoZoomSpeed = 0.5f; // The rate of change of the orthographic size in orthographic mode.
void Update(
Unity 双指缩放脚本
最新推荐文章于 2023-06-27 19:19:33 发布