Skip to content

Instantly share code, notes, and snippets.

@MarcinusX
Created January 14, 2019 05:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save MarcinusX/ce1a7edb4f606b6f485d0464d64e9c0e to your computer and use it in GitHub Desktop.
Save MarcinusX/ce1a7edb4f606b6f485d0464d64e9c0e to your computer and use it in GitHub Desktop.
if (notes[currentNoteIndex].state != NoteState.tapped) {
//game over
setState(() {
isPlaying = false;
notes[currentNoteIndex].state = NoteState.missed; //<-- set note state to missed
});
animationController.reverse(); //<-- reverse last animation
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment