[gd_scene load_steps=9 format=3 uid="uid://d3pb25xuef2t2"] [ext_resource type="Theme" uid="uid://b056fn288p8ha" path="res://logic-scenes/themes/messy.theme" id="1_2apkb"] [ext_resource type="Script" path="res://logic-scenes/collectable/collectable_ui.gd" id="1_tgjc2"] [ext_resource type="Texture2D" uid="uid://d0ucjqi8tx6vt" path="res://import/interface-elements/frame.png" id="3_63j61"] [sub_resource type="GDScript" id="GDScript_g0qhf"] script/source = "@tool extends Button func hide(): if visible == true and not State.reduce_motion: var tween:Tween = create_tween() custom_minimum_size = get_minimum_size() var tmp = text text = \"\" tween.tween_property(self, \"custom_minimum_size\", Vector2(size.x, 0), 0.2) update_minimum_size() await tween.finished visible = false text = tmp update_minimum_size() else: visible = false func show(): if visible == false and not State.reduce_motion: var tmp = text var tween:Tween = create_tween() tween.tween_property(self, \"custom_minimum_size\", get_minimum_size(), 0.2) text = \"\" update_minimum_size() visible = true await tween.finished text = tmp else: visible = true " [sub_resource type="Animation" id="Animation_rhsmi"] length = 0.001 tracks/0/type = "value" tracks/0/imported = false tracks/0/enabled = true tracks/0/path = NodePath("Panel/Content/Buttons:custom_minimum_size") tracks/0/interp = 1 tracks/0/loop_wrap = true tracks/0/keys = { "times": PackedFloat32Array(0), "transitions": PackedFloat32Array(1), "update": 0, "values": [Vector2(0, 256)] } [sub_resource type="Animation" id="Animation_bq4rh"] resource_name = "invisible" length = 0.001 tracks/0/type = "value" tracks/0/imported = false tracks/0/enabled = true tracks/0/path = NodePath("Panel/Content/Buttons:custom_minimum_size") tracks/0/interp = 1 tracks/0/loop_wrap = true tracks/0/keys = { "times": PackedFloat32Array(0), "transitions": PackedFloat32Array(1), "update": 0, "values": [Vector2(0, 0)] } [sub_resource type="Animation" id="Animation_rx43a"] resource_name = "show_buttons" tracks/0/type = "value" tracks/0/imported = false tracks/0/enabled = true tracks/0/path = NodePath("Panel/Content/Buttons:custom_minimum_size") tracks/0/interp = 2 tracks/0/loop_wrap = true tracks/0/keys = { "times": PackedFloat32Array(0, 0.4, 0.6), "transitions": PackedFloat32Array(1, 1, 1), "update": 0, "values": [Vector2(0, 0), Vector2(0, 135), Vector2(0, 130)] } [sub_resource type="AnimationLibrary" id="AnimationLibrary_jad23"] _data = { "RESET": SubResource("Animation_rhsmi"), "invisible": SubResource("Animation_bq4rh"), "show_buttons": SubResource("Animation_rx43a") } [node name="CollectableUi" type="CenterContainer"] anchors_preset = 15 anchor_right = 1.0 anchor_bottom = 1.0 grow_horizontal = 2 grow_vertical = 2 theme = ExtResource("1_2apkb") script = ExtResource("1_tgjc2") [node name="Panel" type="PanelContainer" parent="."] layout_mode = 2 [node name="Content" type="VBoxContainer" parent="Panel"] layout_mode = 2 [node name="Name" type="Label" parent="Panel/Content"] layout_mode = 2 theme_type_variation = &"HeaderLarge" text = "old Mask" horizontal_alignment = 1 [node name="ContentNotes" type="RichTextLabel" parent="Panel/Content"] visible = false custom_minimum_size = Vector2(256, 0) layout_mode = 2 bbcode_enabled = true text = "[center] Content Notes: Food, Blood, Gore, Whatever, I need a second line. [/center]" fit_content = true [node name="Buttons" type="ScrollContainer" parent="Panel/Content"] custom_minimum_size = Vector2(0, 256) layout_mode = 2 horizontal_scroll_mode = 0 vertical_scroll_mode = 3 [node name="VBoxContainer" type="VBoxContainer" parent="Panel/Content/Buttons"] layout_mode = 2 size_flags_horizontal = 3 size_flags_vertical = 3 [node name="collect_or_listen" type="Button" parent="Panel/Content/Buttons/VBoxContainer"] layout_mode = 2 tooltip_text = "Take this with you, and listen to it's story." text = "Collect" script = SubResource("GDScript_g0qhf") [node name="Summary" type="Button" parent="Panel/Content/Buttons/VBoxContainer"] layout_mode = 2 tooltip_text = "Take this with you, but get a neutral description of it's story." text = "get neutral summary" script = SubResource("GDScript_g0qhf") [node name="skip" type="Button" parent="Panel/Content/Buttons/VBoxContainer"] layout_mode = 2 tooltip_text = "Choose this to entirely skip this Item without being unable to progress in the story. Skipped Segments can still be interacted with via the Pause Screen, if you decide to change your mind." text = "skip" script = SubResource("GDScript_g0qhf") [node name="put_back" type="Button" parent="Panel/Content/Buttons/VBoxContainer"] layout_mode = 2 text = "put back" script = SubResource("GDScript_g0qhf") [node name="StartFrame" type="TextureRect" parent="Panel"] layout_mode = 2 mouse_filter = 2 texture = ExtResource("3_63j61") expand_mode = 2 stretch_mode = 4 [node name="AnimationPlayer" type="AnimationPlayer" parent="."] autoplay = "invisible" libraries = { "": SubResource("AnimationLibrary_jad23") } [connection signal="resized" from="Panel/Content/Buttons/VBoxContainer" to="Panel/Content/Buttons" method="_on_v_box_container_resized"] [connection signal="focus_entered" from="Panel/Content/Buttons/VBoxContainer/collect_or_listen" to="." method="_yoink_focus"] [connection signal="focus_entered" from="Panel/Content/Buttons/VBoxContainer/Summary" to="." method="_yoink_focus"] [connection signal="focus_entered" from="Panel/Content/Buttons/VBoxContainer/skip" to="." method="_yoink_focus"] [connection signal="focus_entered" from="Panel/Content/Buttons/VBoxContainer/put_back" to="." method="_yoink_focus"]