Commit 151cbb26 authored by catdog's avatar catdog

NoteHit을 사용하도록 수정

parent 8074cea8
......@@ -134,8 +134,9 @@ class ForwardNote : Note
{
if (Math.Abs(time - this.Time) < 0.5)
{
var obj = MonoBehaviour.Instantiate(PlayEngine.inst.explosion);
obj.transform.position = noteObject.transform.position;
noteObject.NoteHit(NoteHitType.PERFECT);
//var obj = MonoBehaviour.Instantiate(PlayEngine.inst.explosion);
//obj.transform.position = noteObject.transform.position;
}
}
}
......
......@@ -45,8 +45,6 @@ public class ForwardNoteObject : NoteObject
private void Start()
{
NoteHit(NoteHitType.PERFECT);
Debug.Log("A");
}
private void OnDisable()
......
......@@ -38,7 +38,7 @@ public abstract class NoteObject : MonoBehaviour
{
OnNoteHit?.Invoke(type);
Instantiate(PlayEngine.inst.hitEffectPrefabs[(int)type], transform.position, Quaternion.identity);
Destroy(gameObject);
//Destroy(gameObject);
}
public virtual void SetPosition(float remainedTime)
......
......@@ -74,7 +74,6 @@ public class PlayEngine : SingletonBehaviour<PlayEngine>
AudioSource.PlayClipAtPoint(gunSfx, Vector3.zero);
level.HandleInput(time);
}
}
if (Input.GetKeyDown(KeyCode.LeftArrow))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment