added cool animation to springs

This commit is contained in:
zoe 2021-10-18 13:25:09 +02:00
parent 7b67b3aef6
commit a88727b2d8
13 changed files with 267 additions and 47 deletions

View file

@ -0,0 +1,19 @@
extends Node2D
func _ready() -> void:
global_position = Vector2(0, 184)
spawn_animations()
$Particles2D.emitting = true
func spawn_animations():
var Sprite = preload("res://Pegs/Yellow/Powerups/Spawn/FromBottomSprite.tscn")
var counter = 0
while counter <= 12:
var sprite = Sprite.instance()
add_child(sprite)
sprite.play("spawn")
sprite.offset = Vector2(counter * 32, -32)
sprite.global_position = global_position
counter += 1