Class ShooterProjectileType.ProjectileShape

java.lang.Object
com.flarerobotics.lib.control.shooter.data.ShooterProjectileType.ProjectileShape
Direct Known Subclasses:
ShooterProjectileType.ProjectileShape.CuboidHollowThin, ShooterProjectileType.ProjectileShape.CuboidSolid, ShooterProjectileType.ProjectileShape.CylinderHollowThick, ShooterProjectileType.ProjectileShape.CylinderHollowThin, ShooterProjectileType.ProjectileShape.CylinderSolid, ShooterProjectileType.ProjectileShape.Ring, ShooterProjectileType.ProjectileShape.SphereHollowThick, ShooterProjectileType.ProjectileShape.SphereHollowThin, ShooterProjectileType.ProjectileShape.SphereSolid
Enclosing class:
ShooterProjectileType

public abstract static class ShooterProjectileType.ProjectileShape extends Object
Represents various projectile shapes with moment of inertia calculations. All moments are calculated about central axes through center of mass.

For clarification and X-Y-Z axes orientation, check out the wikipedia page https://en.wikipedia.org/wiki/List_of_moments_of_inertia.

  • Constructor Details

    • ProjectileShape

      public ProjectileShape()
  • Method Details

    • inertiaX

      public abstract double inertiaX()
      Calculates moment of inertia about X-axis.
      Returns:
      Moment of inertia about X-axis in kg*m^2.
    • inertiaY

      public abstract double inertiaY()
      Calculates moment of inertia about Y-axis.
      Returns:
      Moment of inertia about Y-axis in kg*m^2.
    • inertiaZ

      public abstract double inertiaZ()
      Calculates moment of inertia about Z-axis.
      Returns:
      Moment of inertia about Z-axis in kg*m^2.