2D sprite node in a 3D world.
    public class Sprite3D : SpriteBase3D

A node that displays a 2D texture in a 3D environment. The texture displayed can be a region from a larger atlas texture, or a frame from a sprite sheet animation.

Inheritance Chain

Constructors

    public Sprite3D()

Signals

    "frame_changed" ()

Emitted when the Frame changes.

Properties

    public int Frame { get; set; }

Current frame to display from sprite sheet. Vframes or Hframes must be greater than 1.

    public Vector2 FrameCoords { get; set; }

Coordinates of the frame to display from sprite sheet. This is as an alias for the Frame property. Vframes or Hframes must be greater than 1.

    public int Hframes { get; set; }

The number of columns in the sprite sheet.

    public bool RegionEnabled { get; set; }

If true, texture will be cut from a larger atlas texture. See RegionRect.

    public Rect2 RegionRect { get; set; }

The region of the atlas texture to display. RegionEnabled must be true.

    public Texture Texture { get; set; }

Texture object to draw.

    public int Vframes { get; set; }

The number of rows in the sprite sheet.

Methods

    [Obsolete("GetFrame is deprecated. Use the Frame property instead.")]
    public int GetFrame()

Getter for Frame

    [Obsolete("GetFrameCoords is deprecated. Use the FrameCoords property instead.")]
    public Vector2 GetFrameCoords()

Getter for FrameCoords

    [Obsolete("GetHframes is deprecated. Use the Hframes property instead.")]
    public int GetHframes()

Getter for Hframes

    [Obsolete("GetRegionRect is deprecated. Use the RegionRect property instead.")]
    public Rect2 GetRegionRect()

Getter for RegionRect

    [Obsolete("GetTexture is deprecated. Use the Texture property instead.")]
    public Texture GetTexture()

Getter for Texture

    [Obsolete("GetVframes is deprecated. Use the Vframes property instead.")]
    public int GetVframes()

Getter for Vframes

    [Obsolete("IsRegion is deprecated. Use the RegionEnabled property instead.")]
    public bool IsRegion()

Getter for RegionEnabled

    [Obsolete("SetFrame is deprecated. Use the Frame property instead.")]
    public void SetFrame(int frame)

Setter for Frame

    [Obsolete("SetFrameCoords is deprecated. Use the FrameCoords property instead.")]
    public void SetFrameCoords(Vector2 coords)

Setter for FrameCoords

    [Obsolete("SetHframes is deprecated. Use the Hframes property instead.")]
    public void SetHframes(int hframes)

Setter for Hframes

    [Obsolete("SetRegion is deprecated. Use the RegionEnabled property instead.")]
    public void SetRegion(bool enabled)

Setter for RegionEnabled

    [Obsolete("SetRegionRect is deprecated. Use the RegionRect property instead.")]
    public void SetRegionRect(Rect2 rect)

Setter for RegionRect

    [Obsolete("SetTexture is deprecated. Use the Texture property instead.")]
    public void SetTexture(Texture texture)

Setter for Texture

    [Obsolete("SetVframes is deprecated. Use the Vframes property instead.")]
    public void SetVframes(int vframes)

Setter for Vframes

Tags: