GraphEditor/Component.gd

19 lines
449 B
GDScript

extends Node2D
var center = Vector2(0,0) # TODO
const full_circle = TAU
var radius
# Called when the node enters the scene tree for the first time.
func _ready():
radius = $StaticBody2D/CollisionShape2D.shape.radius
# Called every frame. 'delta' is the elapsed time since the previous frame.
func _process(delta):
pass
func _draw():
draw_circle(center, radius, Color.GRAY)
draw_arc(center,radius, 0, full_circle, 128, Color.BROWN, 3, true)