java.lang.Object
swervelib.simulation.ironmaple.simulation.SimulatedArena
swervelib.simulation.ironmaple.simulation.seasonspecific.crescendo2024.Arena2024Crescendo

public class Arena2024Crescendo extends SimulatedArena
  • Field Details

    • blueAmpClock

      protected double blueAmpClock
    • blueAmpCount

      protected int blueAmpCount
    • redAmpClock

      protected double redAmpClock
    • redAmpCount

      protected int redAmpCount
    • redSpeaker

      protected final CrescendoSpeaker redSpeaker
    • blueSpeaker

      protected final CrescendoSpeaker blueSpeaker
    • redAmp

      protected final CrescendoAmp redAmp
    • blueAmp

      protected final CrescendoAmp blueAmp
  • Constructor Details

    • Arena2024Crescendo

      public Arena2024Crescendo()
  • Method Details

    • placeGamePiecesOnField

      public void placeGamePiecesOnField()
      Description copied from class: SimulatedArena

      Places Game Pieces on the Field for Autonomous Mode.

      This method sets up the game pieces on the field, typically in their starting positions for autonomous mode.

      It should be implemented differently for each season-specific subclass of SimulatedArena to reflect the unique game piece placements for that season's game.

      Specified by:
      placeGamePiecesOnField in class SimulatedArena
    • simulationSubTick

      public void simulationSubTick(int tickNum)
      Description copied from class: SimulatedArena

      Processes a Single Simulation Sub-Tick.

      This method performs the actions for each sub-tick of the simulation, including:

      Overrides:
      simulationSubTick in class SimulatedArena
    • isAmped

      public boolean isAmped(boolean isBlue)

      Returns wether the specified team currently has an amped speaker

      This function returns true during autonomous since the autonomous mode behaves exactly like amplified game play.

      Parameters:
      isBlue - Wether to check the blue or red alliance.
      Returns:
      Wether the specified alliance is currently amplified.
    • addAmpCharge

      public void addAmpCharge(boolean isBlue)

      Adds a charge to the amp of the specified team. One charge is equal to one note in the amp so two charges are needed to use the amp.

      Parameters:
      isBlue - Wether the charge is added to the blue or red alliance.
    • activateAmp

      public boolean activateAmp(boolean isBlue)

      Activates the amp for the specified team.

      Parameters:
      isBlue - Wether to amplify for the blue or red team.
      Returns:
      Returns true if the amplification was successful and false if it was not.