Class Renderer

java.lang.Object
mindustry.core.Renderer
All Implemented Interfaces:
ApplicationListener

public class Renderer extends Object implements ApplicationListener
  • Field Details

    • laserOpacity

      public static float laserOpacity
      These are global variables, for headless access. Cached.
    • bridgeOpacity

      public static float bridgeOpacity
      These are global variables, for headless access. Cached.
    • blocks

      public final BlockRenderer blocks
    • fog

      public final FogRenderer fog
    • minimap

      public final MinimapRenderer minimap
    • overlays

      public final OverlayRenderer overlays
    • lights

      public final LightRenderer lights
    • pixelator

      public final Pixelator pixelator
    • planets

      public PlanetRenderer planets
    • bloom

      @Nullable public Bloom bloom
    • backgroundBuffer

      @Nullable public FrameBuffer backgroundBuffer
    • effectBuffer

      public FrameBuffer effectBuffer
    • animateShields

      public boolean animateShields
    • drawWeather

      public boolean drawWeather
    • drawStatus

      public boolean drawStatus
    • enableEffects

      public boolean enableEffects
    • drawDisplays

      public boolean drawDisplays
    • drawLight

      public boolean drawLight
    • weatherAlpha

      public float weatherAlpha
    • minZoom

      public float minZoom
      minZoom = zooming out, maxZoom = zooming in
    • maxZoom

      public float maxZoom
      minZoom = zooming out, maxZoom = zooming in
    • envRenderers

      public Seq<Renderer.EnvRenderer> envRenderers
    • customBackgrounds

      public ObjectMap<String,Runnable> customBackgrounds
    • bubbles

      public TextureRegion[] bubbles
    • splashes

      public TextureRegion[] splashes
    • fluidFrames

      public TextureRegion[][] fluidFrames
  • Constructor Details

    • Renderer

      public Renderer()
  • Method Details

    • shake

      public void shake(float intensity, float duration)
    • addEnvRenderer

      public void addEnvRenderer(int mask, Runnable render)
    • addCustomBackground

      public void addCustomBackground(String name, Runnable render)
    • init

      public void init()
      Description copied from interface: ApplicationListener
      Called when the Application is first created. Only gets called if the application is created before the listener is added.
      Specified by:
      init in interface ApplicationListener
    • loadFluidFrames

      public void loadFluidFrames()
    • getFluidFrames

      public TextureRegion[][] getFluidFrames()
    • update

      public void update()
      Description copied from interface: ApplicationListener
      Called when the Application should update itself.
      Specified by:
      update in interface ApplicationListener
    • updateAllDarkness

      public void updateAllDarkness()
    • isCutscene

      public boolean isCutscene()
      Returns:
      whether a launch/land cutscene is playing.
    • landScale

      public float landScale()
    • dispose

      public void dispose()
      Description copied from interface: ApplicationListener
      Called when the Application is destroyed. Preceded by a call to ApplicationListener.pause().
      Specified by:
      dispose in interface ApplicationListener
    • resume

      public void resume()
      Description copied from interface: ApplicationListener
      Called when the Application is resumed from a paused state, usually when it regains focus.
      Specified by:
      resume in interface ApplicationListener
    • toggleBloom

      public void toggleBloom(boolean enabled)
    • draw

      public void draw()
    • drawBackground

      protected void drawBackground()
    • scaleCamera

      public void scaleCamera(float amount)
    • clampScale

      public void clampScale()
    • getDisplayScale

      public float getDisplayScale()
    • minScale

      public float minScale()
    • maxScale

      public float maxScale()
    • getScale

      public float getScale()
    • setScale

      public void setScale(float scl)
    • isLaunching

      public boolean isLaunching()
    • getLaunchCoreType

      public CoreBlock getLaunchCoreType()
    • getLandTime

      public float getLandTime()
    • getLandPTimer

      public float getLandPTimer()
    • setLandPTimer

      public void setLandPTimer(float landPTimer)
    • showLanding

      public void showLanding()
    • showLaunch

      public void showLaunch(CoreBlock coreType)
    • takeMapScreenshot

      public void takeMapScreenshot()