Klasse Area3D
java.lang.Object
net.risingworld.api.worldelements.GameObject
net.risingworld.api.worldelements.Area3D
-
Verschachtelte Klassen - Übersicht
Von Klasse geerbte verschachtelte Klassen/Schnittstellen net.risingworld.api.worldelements.GameObject
GameObject.AttachTarget
-
Konstruktorübersicht
-
Methodenübersicht
Modifizierer und TypMethodeBeschreibunggetArea()
Gets the underlyingArea
.int
getColor()
int
boolean
Gets whether this element is always visible (i.e visible through walls etc) or not.boolean
void
setAlwaysVisible
(boolean set) Determines if the element should be always visible (i.e visible through walls etc) or not.void
Sets the underlyingArea
.void
setColor
(float r, float g, float b, float a) Sets the color (RGBA) of the area (the inner part, not the frame).void
setColor
(int color) void
Sets the color (RGBA) of the area (the inner part, not the frame).void
setFrameColor
(float r, float g, float b, float a) Sets the color (RGBA) of the frame.void
setFrameColor
(int color) Sets the color of the frame.void
setFrameColor
(ColorRGBA color) Sets the color of the frame.void
setFrameVisible
(boolean set) void
Updates this element.Von Klasse geerbte Methoden net.risingworld.api.worldelements.GameObject
addChild, addComponent, attachTo, attachTo, deleteAttribute, getAttribute, getAttributes, getChildCount, getChilds, getCollider, getID, getLayer, getLocalPosition, getLocalRotation, getLocalScale, getParent, getPluginID, hasAttribute, hasAttribute, invokeComponentMethod, isActive, isAttached, isColliderVisible, isDisposed, moveToLocalPosition, moveToLocalPosition, moveToLocalPosition, moveToLocalPosition, moveToLocalTransform, readWorldPosition, readWorldRotation, removeAllChilds, removeChild, removeComponent, removeFromParent, rotateToLocalRotation, setActive, setAttribute, setCollider, setColliderVisible, setComponentEnabled, setComponentProperty, setLayer, setLocalPosition, setLocalPosition, setLocalRotation, setLocalRotation, setLocalScale, setLocalScale
-
Konstruktordetails
-
Area3D
Creates a newArea3D
element which represents an actualArea
. Can be used to visualize anArea
.
Note that changes to theArea
(i.e if you change its coordinates) requires you to update thisArea3D
accordingly.- Parameter:
area
- theArea
you want to represent.
-
-
Methodendetails
-
setArea
Sets the underlyingArea
.- Parameter:
area
- the new area.
-
getArea
Gets the underlyingArea
.- Gibt zurück:
- the area.
-
updateCoordinates
public void updateCoordinates()Updates this element. Call this method if the area coordinates have been changed. Does the same assetArea(getArea());
-
setAlwaysVisible
public void setAlwaysVisible(boolean set) Determines if the element should be always visible (i.e visible through walls etc) or not.- Parameter:
set
- set to true to make this element always visible.
-
isAlwaysVisible
public boolean isAlwaysVisible()Gets whether this element is always visible (i.e visible through walls etc) or not.- Gibt zurück:
- true if this element is always visible, false if not.
-
setFrameVisible
public void setFrameVisible(boolean set) -
isFrameVisible
public boolean isFrameVisible() -
setColor
public void setColor(float r, float g, float b, float a) Sets the color (RGBA) of the area (the inner part, not the frame).- Parameter:
r
- the red color value (0-1)g
- the green color value (0-1)b
- the blue color value (0-1)a
- the alpha value (0-1), 0 makes the area invisible, 1 fully opaque.
-
setColor
Sets the color (RGBA) of the area (the inner part, not the frame).- Parameter:
color
- the new color
-
setColor
public void setColor(int color) -
getColor
public int getColor() -
setFrameColor
public void setFrameColor(float r, float g, float b, float a) Sets the color (RGBA) of the frame.- Parameter:
r
- the red color value (0-1)g
- the green color value (0-1)b
- the blue color value (0-1)a
- the alpha value (0-1), 0 makes the frame invisible, 1 fully opaque.
-
setFrameColor
Sets the color of the frame.- Parameter:
color
- the new color
-
setFrameColor
public void setFrameColor(int color) Sets the color of the frame.- Parameter:
color
- the new color as rgba int (e.g 0xFF0000FF)
-
getFrameColor
public int getFrameColor()
-