2024-10-30 01:08:16 +08:00
|
|
|
using System.Collections;
|
|
|
|
using System.Collections.Generic;
|
|
|
|
using UnityEngine;
|
|
|
|
using System;
|
|
|
|
using DG.Tweening;
|
2024-11-14 16:05:27 +08:00
|
|
|
using UnityEngine.SceneManagement;
|
2024-10-30 01:08:16 +08:00
|
|
|
public class ZuanshiBtn : MonoBehaviour
|
|
|
|
{
|
|
|
|
public static Action OnSceneMouseBTN;
|
2024-11-12 17:35:15 +08:00
|
|
|
public GameObject gotoscene;
|
|
|
|
public GameObject nowScene;
|
2024-10-30 01:08:16 +08:00
|
|
|
// 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()
|
|
|
|
{
|
2024-11-08 16:29:30 +08:00
|
|
|
|
2024-10-30 01:08:16 +08:00
|
|
|
transform.DOScale(Vector3.one, 0.5f).SetEase(Ease.OutBack);
|
|
|
|
OnSceneMouseBTN();
|
2024-11-08 16:29:30 +08:00
|
|
|
|
|
|
|
yield return null;
|
2024-10-30 01:08:16 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
void JUmpScem()
|
|
|
|
{
|
2024-11-12 17:35:15 +08:00
|
|
|
//Virtual_CameraManager.Instance.SwitchToCamera(1);
|
2024-11-16 01:07:21 +08:00
|
|
|
gotoscene.SetActive(true);
|
|
|
|
nowScene.SetActive(false);
|
|
|
|
//SceneManager.LoadScene(JumpScene.scene_baoshidao);
|
2024-10-30 01:08:16 +08:00
|
|
|
}
|
2024-12-24 17:44:00 +08:00
|
|
|
|
|
|
|
private void OnDestroy()
|
|
|
|
{
|
|
|
|
OnSceneMouseBTN -= JUmpScem;
|
|
|
|
}
|
2024-10-30 01:08:16 +08:00
|
|
|
}
|