Input.touchCount 触摸数量

static var touchCount : int

Description描述

Number of touches (Read Only).

触摸的数量。每一帧之内都一定不会改变(只读)

using UnityEngine;
using System.Collections;

public class example : MonoBehaviour {
	void Update() {
		if (Input.touchCount > 0)
			print(Input.touchCount);

	}
}
function Update () {
	if (Input.touchCount > 0) {
		print(Input.touchCount);
	}
}
Page last updated: 2011-3-11