在Update中运行Vector3 mousePos=Camera.main.ScreenToWorldPoint(Input.mousePosition)+new Vector3(0,0,10);这行代码的意思是屏幕坐标转化为三维坐标,然后z轴加10就是正确的位置了transform.position=mous......
usingUnityEngine;usingSystem.Collections;public class MouseEvent_Color : MonoBehaviour { //物体初始颜色 private Color CubeColor; private Texture ...