Closed KatieWoe closed 3 years ago
Further bug that is much odder and may need it's own issue (let me know if you want one @jbphet) If you do this catching behavior on the top loop, the "ghost" magnet appears on the other side of the screen it is trying to get to. If you do it on the bottom loop then the "ghost" magnet appears caught on that loop.
Another small issue, don't know if this will be resolved with fixing the other problems or is related to being caught on the objects. While holding the 1,2,3 buttons and moving the magnet around a second ghost magnet pops up when moving vertically
@emily-phet, @Ashton-Morris, and I discussed the current behavior of the 1,2,3 buttons with respect to reversing the motion of the magnet and decided that it would be better if the magnet always reversed direction when one of these keys is pressed rather than doing what it does now, which is to switch directions only once it has crossed the center line. This should resolve the initially reported problem and hopefully will result in more intuitive behavior.
Should https://github.com/phetsims/faradays-law/issues/196#issuecomment-719841531 get its own issue?
Should https://github.com/phetsims/faradays-law/issues/196#issuecomment-719841531 get its own issue?
No, at least not yet. I am making some pretty major changes to this code, so I'll try to make sure that the inconsistency described there is fixed as well. I came across some buggy code that I think was the root of the discrepancy and have fixed it, so I'm optimistic that it will no longer be a problem when I'm done with this issue.
I've made a lot of changes to this feature, which I'm referring to in the code as the "auto-slide" feature since that's what @terracoda called it in the keyboard help dialog.
@KatieWoe - Can you please test this on master and verify that the two primary problems you reported are resolved? I'm not concerned about the issue that @brooklynlash reported in https://github.com/phetsims/faradays-law/issues/196#issuecomment-720572500. Please assign back to me with your results.
Looks ok on master
Unassigning for now, will have QA verify this on the upcoming release.
I ended up seeing this in 1.4.0-rc.1, but it then stopped and I can't seem to reproduce it again. I'm not sure what caused it and what fixed it.
I'm still not sure of the cause. It seems to be triggered by going back and forth and then hitting the coil. It also makes the metallic ding sound, which it doesn't seem to normally when it hits the coil after using the number buttons. I have also seemed to have more success after refreshing the page. Edit: linking to rc. https://github.com/phetsims/QA/issues/581
Indeed, it was still possible to get the magnet stuck. To do so, the user would have to press one of the auto-slide keys at the moment the magnet hit the coil. There was a single frame time (i.e. a 16 ms window) where the animation was still in progress but the target position had actually been reached, and pressing an auto-slide key at this moment caused the code to get a bit confused. I've modified it so that the animation flag is set to false immediately when the target position is reached, thus eliminating the vulnerability.
I also fixed the problem where the coil-bump sound was not being played on auto-slide key movements.
@KatieWoe - Please test both things on master. In other words, please:
Please assign this back to me with your results so that I can make sure I remember to move the change to the release branch.
Those look good, but I found a similar behavior. If you press more than one of the autoslide keys while the magnet is fully on the right side of the screen, then it gets stuck there until you use the arrow keys to move the magnet. I haven't seen this on the left side of the screen or against magnets, or in the middle of the screen.
Hmm, multiple simultaneous speed-key presses, eh? Well there's a test I never thought to run. I've added code to handle that case, please test on master.
The fixes for the problems related to this issue found in 1.4.0-rc.1 have now been cherry picked to the 1.4 release branch.
I think this is fixed? There is a lot in this issue, and I am somewhat distracted by #214. It's hard for me to know if #214 is one of the bugs listed in this issue, or a regression from one of their fixes, or what. So I am not entirely sure if I want to close this?
I still see differing behavior on that right size, but it no longer seems to make it so you can't use the number sliders.
Other than what @phet-steele saw with https://github.com/phetsims/faradays-law/issues/214, the aspects mentioned here seemed fixed. It's a bit hard to tell with https://github.com/phetsims/faradays-law/issues/196#issuecomment-739050300, since it apparently requires such exact timing, but I haven't managed to reproduce it.
We decided to go with it, and the sim has been published. Closing.
Test device MacBook Air Operating System MacOS 10.15.7 Browser Chrome Problem description For https://github.com/phetsims/QA/issues/568 Fairly minor issue. The keyboard nav dialog describes the 1, 2, and 3 buttons as having the ability to "toggle slide direction." If you press the same button while the magnet is in motion, or when it is on one side of the screen, the magnet switches directions and goes back the other way. If, however, the magnet stops by catching on an object, in this case the wire loops, pressing any of the three buttons don't switch directions. You can use the arrow keys to uncatch it, so this may not need to be addressed.
Visuals
Troubleshooting information: