using System.Collections; using System.Collections.Generic; using UnityEngine; using DG.Tweening; using static GameManager; using UnityEngine.UI; public class CameraToPose : MonoBehaviour { public GameObjectType type; public TapName tapName; public Camera cam; public GameObject go; public void moveTo() { if(go) { if(cam.transform.position!=go.transform.position) cam.transform.DOMove(go.transform.position,1f); cam.transform.rotation = go.transform.rotation; } } public void toggleWindowclick(bool b) { if(b) { GameManager.Instance.showW(type,tapName); moveTo(); } } public void init(GameObjectType type,TapName tapName) { this.type =type; this.tapName =tapName; } }