button.tscn 823 B

1234567891011121314151617181920212223
  1. [gd_scene load_steps=4 format=3 uid="uid://hhi4klksmnov"]
  2. [ext_resource type="Script" path="res://button/button.gd" id="1_4bo1c"]
  3. [ext_resource type="Texture2D" uid="uid://dv08u4k42e12f" path="res://icon.svg" id="1_h2lk7"]
  4. [sub_resource type="RectangleShape2D" id="RectangleShape2D_nfq76"]
  5. size = Vector2(64, 64)
  6. [node name="button" type="Area2D" groups=["buttons"]]
  7. scale = Vector2(0.8, 0.8)
  8. collision_mask = 7
  9. script = ExtResource("1_4bo1c")
  10. [node name="Sprite2D" type="Sprite2D" parent="."]
  11. scale = Vector2(0.5, 0.5)
  12. texture = ExtResource("1_h2lk7")
  13. [node name="CollisionShape2D" type="CollisionShape2D" parent="."]
  14. shape = SubResource("RectangleShape2D_nfq76")
  15. [connection signal="body_entered" from="." to="." method="_on_body_entered"]
  16. [connection signal="body_exited" from="." to="." method="_on_body_exited"]