private bool CheckMatch(BeatInstant x, BeatInstant y) { return (Mathf.Abs (x.time - y.time) < GameplayConfiguration.BEAT_WINDOW_TOLERANCE) && (x.meshes.Contains(y.meshes[0])); }
public bool ProcessInput(MeshFace playerInput) { BeatInstant inputInstant = new BeatInstant (audioSource.time, playerInput); BeatInstant comparisonInstant = bTracker.Peek (); bool hit = CheckMatch (comparisonInstant, inputInstant); if (hit) { bTracker.Dequeue (); ComboCount++; } else { ComboCount = 0; } return hit; }