Bugged trading inventory
This commit is contained in:
parent
2b527c9b2e
commit
793938857e
3 changed files with 136 additions and 45 deletions
|
|
@ -1,9 +1,20 @@
|
|||
[gd_scene load_steps=5 format=3 uid="uid://bdwk0dqcx0xhp"]
|
||||
[gd_scene load_steps=10 format=3 uid="uid://bdwk0dqcx0xhp"]
|
||||
|
||||
[ext_resource type="Script" path="res://scripts/menu/BaseMenu.gd" id="1_0wv8j"]
|
||||
[ext_resource type="Texture2D" uid="uid://db4euprxhape0" path="res://sprites/9s.png" id="1_vb0tn"]
|
||||
[ext_resource type="Script" path="res://scripts/menu/CloseMenuButton.gd" id="2_ld3o5"]
|
||||
[ext_resource type="Script" path="res://scripts/menu/OpenMenuButton.gd" id="3_63o1s"]
|
||||
[ext_resource type="Texture2D" uid="uid://daojdy0tpvsoh" path="res://sprites/items_icons/energy.png" id="5_a74tb"]
|
||||
[ext_resource type="Texture2D" uid="uid://w3aft10s2hxd" path="res://sprites/items_icons/food.png" id="6_36d3e"]
|
||||
[ext_resource type="Texture2D" uid="uid://dlh6eyywjrsk4" path="res://sprites/items_icons/raw_materials.png" id="7_41v33"]
|
||||
[ext_resource type="Texture2D" uid="uid://cova10yh1rlk1" path="res://sprites/items_icons/water.png" id="8_815di"]
|
||||
|
||||
[sub_resource type="GDScript" id="GDScript_ovke4"]
|
||||
script/source = "extends Button
|
||||
|
||||
func _on_button_up():
|
||||
get_parent().visible = false
|
||||
"
|
||||
|
||||
[node name="BaseMenu" type="Control"]
|
||||
process_mode = 1
|
||||
|
|
@ -39,51 +50,40 @@ vertical_alignment = 1
|
|||
[node name="TradingMenuGoto" type="Button" parent="MainMenu"]
|
||||
layout_mode = 0
|
||||
offset_left = 1.0
|
||||
offset_top = 64.0
|
||||
offset_top = 160.0
|
||||
offset_right = 639.0
|
||||
offset_bottom = 192.0
|
||||
text = "Buy / Sell goods"
|
||||
offset_bottom = 224.0
|
||||
text = "Trading"
|
||||
script = ExtResource("3_63o1s")
|
||||
|
||||
[node name="QuestMenuGoto" type="Button" parent="MainMenu"]
|
||||
layout_mode = 0
|
||||
offset_left = 1.0
|
||||
offset_top = 192.0
|
||||
offset_top = 288.0
|
||||
offset_right = 639.0
|
||||
offset_bottom = 320.0
|
||||
text = "Take / Pass the quest"
|
||||
offset_bottom = 352.0
|
||||
text = "Quests"
|
||||
script = ExtResource("3_63o1s")
|
||||
|
||||
[node name="EquipmentMenuGoto" type="Button" parent="MainMenu"]
|
||||
layout_mode = 0
|
||||
offset_left = 1.0
|
||||
offset_top = 320.0
|
||||
offset_top = 416.0
|
||||
offset_right = 639.0
|
||||
offset_bottom = 448.0
|
||||
text = "Change your equipment"
|
||||
offset_bottom = 480.0
|
||||
text = "Equipment"
|
||||
script = ExtResource("3_63o1s")
|
||||
|
||||
[node name="InfoMenuGoto" type="Button" parent="MainMenu"]
|
||||
[node name="MainCloseButton" type="Button" parent="MainMenu"]
|
||||
layout_mode = 0
|
||||
offset_left = 1.0
|
||||
offset_top = 448.0
|
||||
offset_left = 600.0
|
||||
offset_top = 1.0
|
||||
offset_right = 639.0
|
||||
offset_bottom = 576.0
|
||||
text = "About this station"
|
||||
script = ExtResource("3_63o1s")
|
||||
|
||||
[node name="Footer" type="Label" parent="MainMenu"]
|
||||
layout_mode = 0
|
||||
offset_top = 576.0
|
||||
offset_right = 640.0
|
||||
offset_bottom = 640.0
|
||||
text = "Press [TAB] to show / hide menu
|
||||
Fly off the base to exit menu"
|
||||
horizontal_alignment = 1
|
||||
vertical_alignment = 1
|
||||
offset_bottom = 40.0
|
||||
text = "X"
|
||||
script = SubResource("GDScript_ovke4")
|
||||
|
||||
[node name="TradingMenu" type="NinePatchRect" parent="."]
|
||||
visible = false
|
||||
layout_mode = 0
|
||||
offset_left = 320.0
|
||||
offset_top = 40.0
|
||||
|
|
@ -116,50 +116,117 @@ script = ExtResource("2_ld3o5")
|
|||
[node name="SellList" type="ItemList" parent="TradingMenu"]
|
||||
layout_mode = 0
|
||||
offset_left = 1.0
|
||||
offset_top = 64.0
|
||||
offset_top = 96.0
|
||||
offset_right = 320.0
|
||||
offset_bottom = 576.0
|
||||
offset_bottom = 512.0
|
||||
|
||||
[node name="BuyList" type="ItemList" parent="TradingMenu"]
|
||||
layout_mode = 0
|
||||
offset_left = 320.0
|
||||
offset_top = 64.0
|
||||
offset_top = 96.0
|
||||
offset_right = 639.0
|
||||
offset_bottom = 576.0
|
||||
offset_bottom = 512.0
|
||||
|
||||
[node name="SellInput" type="LineEdit" parent="TradingMenu"]
|
||||
layout_mode = 0
|
||||
offset_left = 1.0
|
||||
offset_top = 576.0
|
||||
offset_top = 512.0
|
||||
offset_right = 160.0
|
||||
offset_bottom = 639.0
|
||||
offset_bottom = 576.0
|
||||
placeholder_text = "Amount to buy"
|
||||
alignment = 1
|
||||
|
||||
[node name="BuyInput" type="LineEdit" parent="TradingMenu"]
|
||||
layout_mode = 0
|
||||
offset_left = 320.0
|
||||
offset_top = 576.0
|
||||
offset_top = 512.0
|
||||
offset_right = 480.0
|
||||
offset_bottom = 639.0
|
||||
offset_bottom = 576.0
|
||||
placeholder_text = "Amount to sell"
|
||||
alignment = 1
|
||||
|
||||
[node name="BuyButton" type="Button" parent="TradingMenu"]
|
||||
layout_mode = 0
|
||||
offset_left = 160.0
|
||||
offset_top = 576.0
|
||||
offset_top = 512.0
|
||||
offset_right = 320.0
|
||||
offset_bottom = 639.0
|
||||
text = "Buy selected item"
|
||||
offset_bottom = 576.0
|
||||
text = "Buy"
|
||||
|
||||
[node name="SellButton" type="Button" parent="TradingMenu"]
|
||||
layout_mode = 0
|
||||
offset_left = 480.0
|
||||
offset_top = 576.0
|
||||
offset_top = 512.0
|
||||
offset_right = 639.0
|
||||
offset_bottom = 639.0
|
||||
text = "Sell selected item"
|
||||
offset_bottom = 576.0
|
||||
text = "Sell"
|
||||
|
||||
[node name="LabelBuy" type="Label" parent="TradingMenu"]
|
||||
layout_mode = 0
|
||||
offset_top = 64.0
|
||||
offset_right = 320.0
|
||||
offset_bottom = 96.0
|
||||
text = "Buy"
|
||||
horizontal_alignment = 1
|
||||
vertical_alignment = 1
|
||||
|
||||
[node name="LabelSell" type="Label" parent="TradingMenu"]
|
||||
offset_left = 320.0
|
||||
offset_top = 64.0
|
||||
offset_right = 640.0
|
||||
offset_bottom = 96.0
|
||||
text = "Sell"
|
||||
horizontal_alignment = 1
|
||||
vertical_alignment = 1
|
||||
|
||||
[node name="Energy" type="Sprite2D" parent="TradingMenu"]
|
||||
position = Vector2(17, 608)
|
||||
texture = ExtResource("5_a74tb")
|
||||
|
||||
[node name="Food" type="Sprite2D" parent="TradingMenu"]
|
||||
position = Vector2(177, 608)
|
||||
texture = ExtResource("6_36d3e")
|
||||
|
||||
[node name="RawMaterials" type="Sprite2D" parent="TradingMenu"]
|
||||
position = Vector2(337, 608)
|
||||
texture = ExtResource("7_41v33")
|
||||
|
||||
[node name="Water" type="Sprite2D" parent="TradingMenu"]
|
||||
position = Vector2(497, 608)
|
||||
texture = ExtResource("8_815di")
|
||||
|
||||
[node name="EnergyCount" type="Label" parent="TradingMenu"]
|
||||
layout_mode = 0
|
||||
offset_left = 41.0
|
||||
offset_top = 592.0
|
||||
offset_right = 161.0
|
||||
offset_bottom = 624.0
|
||||
text = "0"
|
||||
vertical_alignment = 1
|
||||
|
||||
[node name="FoodCount" type="Label" parent="TradingMenu"]
|
||||
offset_left = 201.0
|
||||
offset_top = 592.0
|
||||
offset_right = 321.0
|
||||
offset_bottom = 624.0
|
||||
text = "0"
|
||||
vertical_alignment = 1
|
||||
|
||||
[node name="MineralsCount" type="Label" parent="TradingMenu"]
|
||||
offset_left = 361.0
|
||||
offset_top = 592.0
|
||||
offset_right = 481.0
|
||||
offset_bottom = 624.0
|
||||
text = "0"
|
||||
vertical_alignment = 1
|
||||
|
||||
[node name="WaterCount" type="Label" parent="TradingMenu"]
|
||||
offset_left = 521.0
|
||||
offset_top = 592.0
|
||||
offset_right = 640.0
|
||||
offset_bottom = 624.0
|
||||
text = "0"
|
||||
vertical_alignment = 1
|
||||
|
||||
[node name="QuestMenu" type="NinePatchRect" parent="."]
|
||||
visible = false
|
||||
|
|
@ -498,3 +565,5 @@ text = "Actually, this section is WIP.
|
|||
Part of the factions system."
|
||||
horizontal_alignment = 1
|
||||
vertical_alignment = 1
|
||||
|
||||
[connection signal="button_up" from="MainMenu/MainCloseButton" to="MainMenu/MainCloseButton" method="_on_button_up"]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue