cosmic/scripts/Star.gd
Алкесей Мирнеков 3411c5796d
Initial commit (1/2)
2023-11-05 16:23:18 +03:00

12 lines
413 B
GDScript

extends AnimatedSprite2D
# Called when the node enters the scene tree for the first time.
func _ready():
randomize()
var Size : float = randf_range(0.5, 2)
frame = randi_range(0, 7)
scale = Vector2(Size, Size)
speed_scale = randf_range(0, 2)
var Colors = [Color.LIGHT_BLUE, Color.WHITE, Color.LIGHT_GOLDENROD, Color.YELLOW, Color.ORANGE, Color.ORANGE_RED, Color.RED]
modulate = Colors[randi_range(0, 6)]