Skip to content

Commit

Permalink
fix: hide despawning nodes
Browse files Browse the repository at this point in the history
  • Loading branch information
akorzunin committed Aug 8, 2024
1 parent daa3fe7 commit 713318b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/models/icosahedron/components/Icosahedron.gd
Original file line number Diff line number Diff line change
Expand Up @@ -94,8 +94,9 @@ func _on_scale_tick() -> void:
scale_object_local(Vector3(sf, sf, sf))

func despawn():
scaling_enabled = false
var tw = create_tween()
var s := 100.
tw.tween_property(mesh_icosahedron, "scale", Vector3(s, s, s), .3)
tw.tween_property(mesh_icosahedron, "transparency", 0, .8)
tw.finished.connect(func(): queue_free())
tw.play()

0 comments on commit 713318b

Please sign in to comment.