44 lines
1.0 KiB
C#
44 lines
1.0 KiB
C#
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
using System;
|
|
using DG.Tweening;
|
|
using UnityEngine.SceneManagement;
|
|
public class DuanzaoBtn : MonoBehaviour
|
|
{
|
|
public static Action OnSceneMouseBTN;
|
|
public GameObject gotoscene;
|
|
public GameObject nowScene;
|
|
// Start is called before the first frame update
|
|
void Start()
|
|
{
|
|
OnSceneMouseBTN += JUmpScem;
|
|
}
|
|
|
|
|
|
private void OnMouseDown()
|
|
{
|
|
//SceneManager.LoadScene(JumpScene.cultivation_Jinsha_mine_slices);
|
|
transform.DOScale(new Vector3(0.5f, 0.5f, 0.5f), 0.3f).SetEase(Ease.OutBack);
|
|
StartCoroutine("Magnify");
|
|
}
|
|
|
|
|
|
IEnumerator Magnify()
|
|
{
|
|
|
|
transform.DOScale(Vector3.one, 0.5f).SetEase(Ease.OutBack);
|
|
OnSceneMouseBTN();
|
|
|
|
yield return null;
|
|
}
|
|
|
|
void JUmpScem()
|
|
{
|
|
//Virtual_CameraManager.Instance.SwitchToCamera(1);
|
|
gotoscene.SetActive(true);
|
|
nowScene.SetActive(false);
|
|
//SceneManager.LoadScene(JumpScene.scene_forging);
|
|
}
|
|
}
|