brackeys-12/ui/BuildingIcon.tscn
2024-09-13 20:09:38 -04:00

37 lines
1.4 KiB
Text

[gd_scene load_steps=5 format=3 uid="uid://b7o2i7tgirg64"]
[ext_resource type="Script" path="res://ui/building_icon.gd" id="1_6qgij"]
[ext_resource type="Texture2D" uid="uid://c3t66sxwk078m" path="res://parts/buildings/images/essencecompressor.png" id="1_62uie"]
[ext_resource type="PackedScene" uid="uid://dykc1mgg5uopw" path="res://components/Cursor/MouseHandler.tscn" id="3_tf3sl"]
[sub_resource type="RectangleShape2D" id="RectangleShape2D_0bdxp"]
[node name="BuildingIcon" type="ColorRect"]
custom_minimum_size = Vector2(32, 32)
script = ExtResource("1_6qgij")
[node name="TextureRect" type="TextureRect" parent="."]
layout_mode = 1
anchors_preset = 8
anchor_left = 0.5
anchor_top = 0.5
anchor_right = 0.5
anchor_bottom = 0.5
offset_left = -24.0
offset_top = -24.0
offset_right = 24.0
offset_bottom = 24.0
grow_horizontal = 2
grow_vertical = 2
texture = ExtResource("1_62uie")
[node name="MouseHandler" parent="." instance=ExtResource("3_tf3sl")]
position = Vector2(16, 17)
[node name="CollisionShape2D" type="CollisionShape2D" parent="MouseHandler"]
shape = SubResource("RectangleShape2D_0bdxp")
[connection signal="clicked" from="MouseHandler" to="." method="_on_mouse_handler_clicked"]
[connection signal="hovered" from="MouseHandler" to="." method="_on_mouse_handler_hovered"]
[connection signal="released" from="MouseHandler" to="." method="_on_mouse_handler_released"]
[connection signal="unhovered" from="MouseHandler" to="." method="_on_mouse_handler_unhovered"]