Package mindustry.core
Class Renderer
java.lang.Object
mindustry.core.Renderer
- All Implemented Interfaces:
ApplicationListener
-
Nested Class Summary
-
Field Summary
Modifier and TypeFieldDescriptionboolean
final BlockRenderer
static float
These are global variables, for headless access.boolean
boolean
boolean
boolean
boolean
TextureRegion[][]
final FogRenderer
static float
These are global variables, for headless access.final LightRenderer
float
minZoom = zooming out, maxZoom = zooming infinal MinimapRenderer
float
minZoom = zooming out, maxZoom = zooming infinal OverlayRenderer
final Pixelator
float
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addCustomBackground
(String name, Runnable render) void
addEnvRenderer
(int mask, Runnable render) void
void
dispose()
Called when theApplication
is destroyed.void
draw()
protected void
float
TextureRegion[][]
float
float
float
getScale()
void
init()
Called when theApplication
is first created.boolean
boolean
float
void
float
maxScale()
float
minScale()
void
resume()
Called when theApplication
is resumed from a paused state, usually when it regains focus.void
scaleCamera
(float amount) void
setLandPTimer
(float landPTimer) void
setScale
(float scl) void
shake
(float intensity, float duration) void
void
showLaunch
(CoreBlock coreType) void
void
toggleBloom
(boolean enabled) void
update()
Called when theApplication
should update itself.void
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface arc.ApplicationListener
exit, fileDropped, pause, resize
-
Field Details
-
laserOpacity
public static float laserOpacityThese are global variables, for headless access. Cached. -
bridgeOpacity
public static float bridgeOpacityThese are global variables, for headless access. Cached. -
blocks
-
fog
-
minimap
-
overlays
-
lights
-
pixelator
-
planets
-
bloom
-
backgroundBuffer
-
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 minZoomminZoom = zooming out, maxZoom = zooming in -
maxZoom
public float maxZoomminZoom = zooming out, maxZoom = zooming in -
envRenderers
-
customBackgrounds
-
bubbles
-
splashes
-
fluidFrames
-
-
Constructor Details
-
Renderer
public Renderer()
-
-
Method Details
-
shake
public void shake(float intensity, float duration) -
addEnvRenderer
-
addCustomBackground
-
init
public void init()Description copied from interface:ApplicationListener
Called when theApplication
is first created. Only gets called if the application is created before the listener is added.- Specified by:
init
in interfaceApplicationListener
-
loadFluidFrames
public void loadFluidFrames() -
getFluidFrames
-
update
public void update()Description copied from interface:ApplicationListener
Called when theApplication
should update itself.- Specified by:
update
in interfaceApplicationListener
-
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 theApplication
is destroyed. Preceded by a call toApplicationListener.pause()
.- Specified by:
dispose
in interfaceApplicationListener
-
resume
public void resume()Description copied from interface:ApplicationListener
Called when theApplication
is resumed from a paused state, usually when it regains focus.- Specified by:
resume
in interfaceApplicationListener
-
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
-
getLandTime
public float getLandTime() -
getLandPTimer
public float getLandPTimer() -
setLandPTimer
public void setLandPTimer(float landPTimer) -
showLanding
public void showLanding() -
showLaunch
-
takeMapScreenshot
public void takeMapScreenshot()
-