关卡1流程实现(测试版)
This commit is contained in:
@@ -1,11 +1,11 @@
|
||||
using System.Collections.Generic;
|
||||
using A2W;
|
||||
using Unity.Cinemachine;
|
||||
using UnityEngine;
|
||||
using UnityEngine.InputSystem;
|
||||
|
||||
public class MusicGame : MonoBehaviour
|
||||
public class MusicGame : SceneSingleton<MusicGame>
|
||||
{
|
||||
public static MusicGame Instance { get; private set; }
|
||||
public MusicData musicData;
|
||||
private bool isPlaying = false;
|
||||
public Camera mainCamera;
|
||||
@@ -19,12 +19,12 @@ public class MusicGame : MonoBehaviour
|
||||
void Start()
|
||||
{
|
||||
mainCamera = Camera.main;
|
||||
Instance = this;
|
||||
|
||||
}
|
||||
|
||||
void Update()
|
||||
{
|
||||
if (Keyboard.current.qKey.wasPressedThisFrame) Play();
|
||||
// if (Keyboard.current.qKey.wasPressedThisFrame) Play();
|
||||
}
|
||||
|
||||
public void Play()
|
||||
@@ -98,6 +98,7 @@ public class MusicGame : MonoBehaviour
|
||||
noteId = 0;
|
||||
mainCamera.GetComponent<CinemachineBrain>().enabled = true;
|
||||
Debug.Log("完成所有tick");
|
||||
GameFlowMgr.instance.completeLevel(0);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user