phetsims / build-an-atom

"Build an Atom" is an educational simulation in HTML5, by PhET Interactive Simulations.
http://phet.colorado.edu/en/simulation/build-an-atom
GNU General Public License v3.0
11 stars 10 forks source link

clean up stuff related to LevelCompletedNode changes #73

Closed pixelzoom closed 10 years ago

pixelzoom commented 11 years ago

Changes were made in to LevelCompletedNode in https://github.com/phetsims/vegas/issues/2

Here's what I put in BAAGameView so that BAA would run:

var isNewBestTime = ( gameModel.elapsedTime >= gameModel.bestTimes[ gameModel.level ] ); //TODO this is not correct, needs to be computed before best time is set
var bestTime = ( gameModel.bestTimes[ gameModel.level ] === Number.POSITIVE_INFINITY ) ? null: gameModel.bestTimes[ gameModel.level ]; //TODO use null to indicate no best time

You'll probably want to use 'null' in your model for 'no best time'. And you'll need to compute isNewBestTime so that it doesn't have the pitfalls mentioned in the https://github.com/phetsims/vegas/issues/2

jbphet commented 10 years ago

This was done a while ago, and issue was never closed. Closing now.