phetsims / pendulum-lab

"Pendulum Lab" is an educational simulation in HTML5, by PhET Interactive Simulations.
GNU General Public License v3.0
4 stars 10 forks source link

Angular displacement tick marks visible after pendulum 2 removed #121

Closed arouinfar closed 8 years ago

arouinfar commented 8 years ago

In dev.6, I noticed that if I switched to from two-pendulum to one-pendulum mode while both pendulums are swinging, the tick marks showing Pendulum 2's angular displacement are still visible.

image image

I suspect Pendulum 2's tick marks are still visible because if I switch back to the two-pendulum view Pendulum 2 is still swinging. However, I don't think the tick marks should be visible if the pendulum is not.

jonathanolson commented 8 years ago

If the red tick marks disappear when switching to 1 pendulum, should they reappear when they go back to 2 pendulums?

The sim code is pretty much "tick marks turn on when the user drags the pendulum, and is only turned off by reset".

The design doc notes:

The blue tick marks will remain on the protractor until the pendulum is dragged to another location or the sim is reset.

I didn't see anything else about that behavior.

arouinfar commented 8 years ago

If the red tick marks disappear when switching to 1 pendulum, should they reappear when they go back to 2 pendulums?

Yes, this would be the ideal behavior.

The design doc notes:

The blue tick marks will remain on the protractor until the pendulum is dragged to another location or the sim is reset.

I re-read that section of the design doc for context (it's been awhile). From looking at it, it's clear to me that I hadn't thought about the situation described in this issue. I can tell I was just playing with it in one-pendulum mode to figure out the tick behavior. Sorry for the discrepancy. I'll update the design doc accordingly.

Technically, the current behavior is not a "bug" as I originally thought, but it's still not ideal. It doesn't make sense to show information related to an invisible pendulum.