Module technology.sola.engine
Class LayerComponent
java.lang.Object
technology.sola.engine.graphics.components.LayerComponent
- All Implemented Interfaces:
technology.sola.ecs.Component
LayerComponent is a
Component
that contains data for a 2d rendering layers for an Entity
.-
Constructor Summary
ConstructorsConstructorDescriptionLayerComponent
(String layer) Creates a LayerComponent for the desired layer with default ordering.LayerComponent
(String layer, int order) Creates a LayerComponent for the desired layer with default ordering. -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface technology.sola.ecs.Component
afterDeserialize
-
Constructor Details
-
LayerComponent
Creates a LayerComponent for the desired layer with default ordering.- Parameters:
layer
- the identifier string for the layer
-
LayerComponent
Creates a LayerComponent for the desired layer with default ordering.- Parameters:
layer
- the identifier string for the layerorder
- the order for which this will be rendered in the layer (lower numbers are rendered earlier)
-
-
Method Details
-
getLayer
- Returns:
- the layer string identifier
-
getOrder
public int getOrder()- Returns:
- the order in the layer
-
setLayer
Updates the layer.- Parameters:
layer
- the new layer string identifier
-
setOrder
public void setOrder(int order) Updates the order in the layer.- Parameters:
order
- the new order
-