TrebuchetSimulator simulator = (TrebuchetSimulator) getSimulator();
Trebuchet treb = simulator.getTrebuchet();
counterWeightLeverlLengthField_ =
new NumberInput( "Counter Weight Lever Length (1.0 short - 3.0 long): ",
treb.getCounterWeightLeverLength(),
"This controls the distance from the fulcrum point to the point "
+ "where the counter weight is attached to the the end of the arm.",
1.0, 3.0, false);
counterWeightMassField_ =
new NumberInput( "Counter Weight Mass (2.0 light - 60.0 heavy): ",
treb.getCounterWeightMass(),
"This controls mass of main counterweight on the right ",
2.0, 60.0, false);
projectileMassField_ =
new NumberInput( "Projectile Mass (0.2 light - 5.0 heavy): ",
treb.getProjectileMass(),
"This controls mass of the projectile thrown.",
0.2, 5.0, false);
slingLengthField_ =
new NumberInput( "Sling Length (0.2 short - 3.0 long): ",
treb.getSlingLength(),
"This controls the magnitude of the sling.",
0.2, 3.0, false);
slingLeverLengthField_ =
new NumberInput( "Sling Lever Length (1.0 short - 5.0 long): ",
treb.getSlingLeverLength(),
"This controls magnitude of the lever arm from the fulcrum to the sling attachment point.",
1.0, 5.0, false);
slingReleaseAngleField_ =
new NumberInput( "Sling Release Angle (0.0 small - PI/2 large): ",
treb.getSlingReleaseAngle(),
"The angle between the sling and the lever arm when the projectile will be released. ",
0, Math.PI / 2, false);
trebParamPanel.add( counterWeightLeverlLengthField_ );