Klasse UIMesh

java.lang.Object
net.risingworld.api.ui.UIElement
net.risingworld.api.ui.UIMesh
Alle implementierten Schnittstellen:
Serializable

public class UIMesh extends UIElement
Represents a UI mesh. It enables you to create custom shapes and elements on the screen. For a simplified version, you can use the UIPainter2D instead, which provides a Vector API to create shapes.

Please note that most style properties have no impact on the UIMesh!

Another note: Unity internally has a hard-coded mesh vertex limit of 65535 for UI elements. If the amount of vertices exceed this value, the UI element can no longer be rendered. Unfortunately there is no workaround available yet, so if you need to work with more than 65535 vertices, you have to split the element into multiple UIMeshes.
Siehe auch:
  • Konstruktordetails

    • UIMesh

      public UIMesh()
  • Methodendetails

    • setTexture

      public void setTexture(TextureAsset texture)
    • setNextVertex

      public void setNextVertex(Vector2f position, Vector2f uv)
    • setNextVertex

      public void setNextVertex(Vector2f position, float r, float g, float b, float a)
    • setNextVertex

      public void setNextVertex(Vector2f position, ColorRGBA color)
    • setNextVertex

      public void setNextVertex(Vector2f position, Vector2f uv, float r, float g, float b, float a)
    • setNextIndex

      public void setNextIndex(short index)
    • clear

      public void clear()
    • update

      public void update()