mirror of
https://github.com/godotengine/godot-demo-projects.git
synced 2025-12-16 05:20:06 +01:00
16 lines
241 B
GDScript
16 lines
241 B
GDScript
class_name Bullet
|
|
extends RigidBody2D
|
|
|
|
var disabled: bool = false
|
|
|
|
func _ready() -> void:
|
|
($Timer as Timer).start()
|
|
|
|
|
|
func disable() -> void:
|
|
if disabled:
|
|
return
|
|
|
|
($AnimationPlayer as AnimationPlayer).play(&"shutdown")
|
|
disabled = true
|