phetsims / neuron

"Neuron" is an educational simulation in HTML5, by PhET Interactive Simulations.
GNU General Public License v3.0
1 stars 3 forks source link

Investigate if speedProperty is really needed in Playback.js #99

Closed jbphet closed 8 years ago

jbphet commented 8 years ago

While working on #88, I found the the simulation speed was being controlled by what seems like an odd combination of interactions with the clock adapter (NeuronClockAdapter.js) and the code that implements the playback mode (Playback.js) for the record/playback feature. It's challenging to get one's head around. Why not just clock the model forward and backwards, by larger and smaller amounts for the different speeds? Why does the playback mode need to know anything about the speed? I think it is worth investigating the removal of the speed property from the playback mode entirely, and maintaining the speed information in only one location.

jbphet commented 8 years ago

This property was removed and the information consolidated into the clock adapter. So far everything appears fine. Closing.