phetsims / friction

"Friction" is an educational simulation in HTML5, by PhET Interactive Simulations.
http://phet.colorado.edu/en/simulation/friction
GNU General Public License v3.0
4 stars 6 forks source link

Reset warming/cooling indexing when settled #256

Closed zepumph closed 2 years ago

zepumph commented 2 years ago

In addition to reset on endDrag, it is nice to reset this when we settle things out. I accidentally already committed half of this over in https://github.com/phetsims/friction/issues/253:

https://github.com/phetsims/friction/blob/53827d7d2e61143852ec84660040a16b8f4f2c9a/js/friction/view/TemperatureDecreasingAlerter.js#L114-L120

I'll complete it here.

zepumph commented 2 years ago

Buggy behavior before this work:

Now once settled, it will reset and start with "warmer" again, and basic "cooler" alerts too. This is pretty much just for mouse because you can't keep a drag really like that with a keyboard (keeping a key pressed). Though I'm sure it's possible.

Closing