phetsims / projectile-motion

"Projectile Motion" is an educational simulation in HTML5, by PhET Interactive Simulations.
GNU General Public License v3.0
16 stars 13 forks source link

PhetIO Studio wrapper Drag Coefficient crash #214

Closed loganbraywork closed 4 years ago

loganbraywork commented 4 years ago

Test Device

Windows 7 Laptop

Operating System

Windows 7

Browser

Chrome

Problem Description Tested on request for Michael Kauzmann In phet.io studio If projectileDragCoefficientProperty is set to 0 then a projectile is emitted, sim crashes

Steps to Reproduce

  1. Open phet.io studio wrapper
  2. Go to vector screen
  3. Under vector screen, model, and projectileDragCoefficientProperty set slider to 0
  4. Attempt to fire projectile in sim

Visuals

2019-12-06DrgCoefIOPrjctlMtn

loganbraywork commented 4 years ago

Also occurs if object diameter set to 0 under the same screen

zepumph commented 4 years ago

This should be fixed as part of https://github.com/phetsims/projectile-motion/issues/217. The issue was just that that slider had no business being able to go down to 0. In the range the lower bound of the range is .04, so I just made just that that numberProperty had the appropriate range. Good bug thanks!

Please confirm fixed on master and close if all is good.

zepumph commented 4 years ago

I also added ranges for mass and diameter so hopefully these sliders won't cause any more bugs.

zepumph commented 4 years ago

This needed a bit more reworking over in #217, but it should be good now.

Please confirm fixed on master and close if all is good.

zepumph commented 4 years ago

@loganbraywork anything else here?

zepumph commented 4 years ago

@loganbraywork I'm going to close this, please reopen if there is anything more.