Class Logic

java.lang.Object
mindustry.core.Logic
All Implemented Interfaces:
arc.ApplicationListener

public class Logic extends Object implements arc.ApplicationListener
Logic module. Handles all logic for entities and waves. Handles game state events. Does not store any game state itself.

This class should not call any outside methods to change state of modules, but instead fire events.

  • Constructor Details

    • Logic

      public Logic()
  • Method Details

    • play

      public void play()
      Adds starting items, resets wave time, and sets state to playing.
    • reset

      public void reset()
    • skipWave

      public void skipWave()
    • runWave

      public void runWave()
    • updateWeather

      protected void updateWeather()
    • sectorCapture

      public static void sectorCapture()
    • updateGameOver

      public static void updateGameOver(Team winner)
    • gameOver

      public static void gameOver(Team winner)
    • researched

      public static void researched(Content content)
    • dispose

      public void dispose()
      Specified by:
      dispose in interface arc.ApplicationListener
    • update

      public void update()
      Specified by:
      update in interface arc.ApplicationListener
    • isWaitingWave

      public boolean isWaitingWave()
      Returns:
      whether the wave timer is paused due to enemies