class Diorite::Command2D

Overview

Internal command payload representing an immediate-mode 2D draw request.

Defined in:

diorite/core/debug_command.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(kind : ShapeKind2D, color : Godot::Color = Godot::Color.new(1.0_f32, 1.0_f32, 1.0_f32, 1.0_f32), duration : Float64 = 0.0) #

Creates a new 2D command with default parameters.


[View source]

Instance Method Detail

def b0 : Bool #

Boolean parameter 0 (e.g. horizontal bar chart orientation).


[View source]
def b0=(b0 : Bool) #

Boolean parameter 0 (e.g. horizontal bar chart orientation).


[View source]
def bar_data : Array(BarData) | Nil #

Bar elements for 2D bar chart or histogram.


[View source]
def bar_data=(bar_data : Array(BarData) | Nil) #

Bar elements for 2D bar chart or histogram.


[View source]
def channel : String #

Filter channel / layer category this command belongs to.


[View source]
def channel=(channel : String) #

Filter channel / layer category this command belongs to.


[View source]
def color : Godot::Color #

Modulate vertex color for this shape.


[View source]
def color=(color : Godot::Color) #

Modulate vertex color for this shape.


[View source]
def duration : Float64 #

Total lifetime duration in seconds (0.0 for single-frame).


[View source]
def duration=(duration : Float64) #

Total lifetime duration in seconds (0.0 for single-frame).


[View source]
def expired? : Bool #

Returns true if the command has exceeded its duration lifetime.


[View source]
def f0 : Float32 #

Float parameter 0 (radius or arrowhead size).


[View source]
def f0=(f0 : Float32) #

Float parameter 0 (radius or arrowhead size).


[View source]
def f1 : Float32 #

Float parameter 1 (auxiliary float, e.g. inner radius or secondary size).


[View source]
def f1=(f1 : Float32) #

Float parameter 1 (auxiliary float, e.g. inner radius or secondary size).


[View source]
def f2 : Float32 #

Float parameter 2 (start angle or auxiliary float).


[View source]
def f2=(f2 : Float32) #

Float parameter 2 (start angle or auxiliary float).


[View source]
def f3 : Float32 #

Float parameter 3 (end angle or auxiliary float).


[View source]
def f3=(f3 : Float32) #

Float parameter 3 (end angle or auxiliary float).


[View source]
def filled : Bool #

Whether the 2D primitive is filled or wireframe.


[View source]
def filled=(filled : Bool) #

Whether the 2D primitive is filled or wireframe.


[View source]
def i0 : Int32 #

Integer parameter 0 (circle segment resolution).


[View source]
def i0=(i0 : Int32) #

Integer parameter 0 (circle segment resolution).


[View source]
def kind : ShapeKind2D #

The kind of 2D primitive to render.


[View source]
def kind=(kind : ShapeKind2D) #

The kind of 2D primitive to render.


[View source]
def p0 : Godot::Vector2 #

2D point 0 (start point or center coordinate).


[View source]
def p0=(p0 : Godot::Vector2) #

2D point 0 (start point or center coordinate).


[View source]
def p1 : Godot::Vector2 #

2D point 1 (end coordinate).


[View source]
def p1=(p1 : Godot::Vector2) #

2D point 1 (end coordinate).


[View source]
def pie_slices : Array(PieSlice) | Nil #

Chart slices for 2D pie or donut charts.


[View source]
def pie_slices=(pie_slices : Array(PieSlice) | Nil) #

Chart slices for 2D pie or donut charts.


[View source]
def points : Array(Godot::Vector2) | Nil #

Polyline vertex array.


[View source]
def points=(points : Array(Godot::Vector2) | Nil) #

Polyline vertex array.


[View source]
def rect : Godot::Rect2 #

Bounding rectangle for 2D box or telemetry graph viewport.


[View source]
def rect=(rect : Godot::Rect2) #

Bounding rectangle for 2D box or telemetry graph viewport.


[View source]
def remaining_time : Float64 #

Remaining lifetime in seconds before this command expires.


[View source]
def remaining_time=(remaining_time : Float64) #

Remaining lifetime in seconds before this command expires.


[View source]
def step(delta : Float64) : Void #

Advances time by delta seconds, decaying remaining duration.


[View source]
def title : String #

Chart title label.


[View source]
def title=(title : String) #

Chart title label.


[View source]