code-dot-org / dance-party

Renderer for the Dance game type. Based on p5.js and p5.play.js.

Home Page:https://code-dot-org.github.io/dance-party/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Add a "Start at measure {n}" feature

islemaster opened this issue · comments

The problem: Iterating on the last part of a dance party project (near the end of the song) can be very, very slow because you have to listen through the first part of the song in real-time every time you want to test your changes.

Proposed solution: Add a debug feature for starting playback at a particular measure.

Considerations:

Dance Party code is highly stateful (creating dancers, setting effects, etc) so instead of only executing student code that occurs after measure n we probably need to "fast-forward" through all of their code up to that point, executing events before measure n sequentially and as fast as possible. (This roughly mirrors the behavior of sinon's fake timers tick() method.)