SelectableLabel.tscn 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. [gd_scene load_steps=7 format=3 uid="uid://bmn81e10obpjv"]
  2. [ext_resource type="Script" uid="uid://c8xv30jxw6uum" path="res://Scripts/UI/SelectableLabel.gd" id="1_bg4p8"]
  3. [ext_resource type="Texture2D" uid="uid://3p2l7rec0gh5" path="res://Assets/Sprites/UI/Cursor.png" id="2_rfswy"]
  4. [ext_resource type="Script" uid="uid://cbal8ms2oe1ik" path="res://Scripts/Classes/Components/ResourceSetterNew.gd" id="3_tbqr7"]
  5. [ext_resource type="JSON" path="res://Assets/Sprites/UI/Cursor.json" id="4_2podj"]
  6. [sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_bg4p8"]
  7. [sub_resource type="AtlasTexture" id="AtlasTexture_wit67"]
  8. atlas = ExtResource("2_rfswy")
  9. region = Rect2(0, 0, 8, 8)
  10. [node name="SelectableLabel" type="Label"]
  11. offset_right = 40.0
  12. offset_bottom = 16.0
  13. focus_mode = 2
  14. theme_override_styles/focus = SubResource("StyleBoxEmpty_bg4p8")
  15. text = "adada"
  16. uppercase = true
  17. script = ExtResource("1_bg4p8")
  18. [node name="Cursor" type="TextureRect" parent="."]
  19. visible = false
  20. layout_mode = 1
  21. anchors_preset = -1
  22. anchor_top = 0.5
  23. anchor_bottom = 0.5
  24. offset_left = -6.0
  25. offset_top = -4.0
  26. offset_bottom = 4.0
  27. grow_vertical = 2
  28. texture = SubResource("AtlasTexture_wit67")
  29. [node name="ResourceSetterNew" type="Node" parent="Cursor" node_paths=PackedStringArray("node_to_affect")]
  30. script = ExtResource("3_tbqr7")
  31. node_to_affect = NodePath("..")
  32. property_name = "texture"
  33. mode = 1
  34. resource_json = ExtResource("4_2podj")
  35. metadata/_custom_type_script = "uid://cbal8ms2oe1ik"
  36. [connection signal="focus_entered" from="." to="Cursor" method="show"]
  37. [connection signal="focus_entered" from="." to="." method="toggle_process" binds= [true]]
  38. [connection signal="focus_exited" from="." to="Cursor" method="hide"]
  39. [connection signal="focus_exited" from="." to="." method="toggle_process" binds= [false]]
  40. [connection signal="ready" from="." to="." method="toggle_process" binds= [false]]