Fix really annoying bug on focus modes. i forgot what else i did but probably added armor
This commit is contained in:
@@ -28,6 +28,7 @@ collision_mask = 0
|
|||||||
|
|
||||||
[node name="Sprite" type="Sprite3D" parent="Pickup"]
|
[node name="Sprite" type="Sprite3D" parent="Pickup"]
|
||||||
unique_name_in_owner = true
|
unique_name_in_owner = true
|
||||||
|
pixel_size = 0.005
|
||||||
billboard = 2
|
billboard = 2
|
||||||
shaded = true
|
shaded = true
|
||||||
texture_filter = 0
|
texture_filter = 0
|
||||||
|
|||||||
@@ -29,6 +29,7 @@ collision_mask = 0
|
|||||||
[node name="Sprite" type="Sprite3D" parent="Pickup"]
|
[node name="Sprite" type="Sprite3D" parent="Pickup"]
|
||||||
unique_name_in_owner = true
|
unique_name_in_owner = true
|
||||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, -0.370004, 0)
|
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, -0.370004, 0)
|
||||||
|
pixel_size = 0.005
|
||||||
billboard = 2
|
billboard = 2
|
||||||
texture_filter = 0
|
texture_filter = 0
|
||||||
|
|
||||||
|
|||||||
@@ -13,10 +13,10 @@ _ferrumResistance = 0.0
|
|||||||
_holyResistance = 0.0
|
_holyResistance = 0.0
|
||||||
_curseResistance = 0.0
|
_curseResistance = 0.0
|
||||||
Name = "Atoner's Adornments"
|
Name = "Atoner's Adornments"
|
||||||
Description = "+1 DEF"
|
Description = ""
|
||||||
SpawnRate = 0.25
|
SpawnRate = 0.25
|
||||||
BonusAttack = 0
|
BonusAttack = 0
|
||||||
BonusDefense = 1
|
BonusDefense = 0
|
||||||
BonusLuck = 0.05
|
BonusLuck = 0.05
|
||||||
BonusHP = 0
|
BonusHP = 0
|
||||||
BonusVT = 0
|
BonusVT = 0
|
||||||
|
|||||||
33
Zennysoft.Game.Ma/src/items/armor/resources/BlastArmor.tres
Normal file
33
Zennysoft.Game.Ma/src/items/armor/resources/BlastArmor.tres
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
[gd_resource type="Resource" script_class="ArmorStats" load_steps=3 format=3 uid="uid://dnj4ybk0fhntx"]
|
||||||
|
|
||||||
|
[ext_resource type="Texture2D" uid="uid://ckt7wupdlylo2" path="res://src/items/armor/textures/HolyArmor2.png" id="1_8mgq5"]
|
||||||
|
[ext_resource type="Script" uid="uid://dqtp6ewvttoyu" path="res://src/items/armor/ArmorStats.cs" id="2_3srmd"]
|
||||||
|
|
||||||
|
[resource]
|
||||||
|
script = ExtResource("2_3srmd")
|
||||||
|
_telluricResistance = 0.0
|
||||||
|
_aeolicResistance = 0.0
|
||||||
|
_hydricResistance = 0.0
|
||||||
|
_igneousResistance = 0.0
|
||||||
|
_ferrumResistance = 0.0
|
||||||
|
_holyResistance = 0.0
|
||||||
|
_curseResistance = 0.0
|
||||||
|
Name = "Blast Armor"
|
||||||
|
Description = ""
|
||||||
|
SpawnRate = 0.5
|
||||||
|
BonusAttack = 0
|
||||||
|
BonusDefense = 4
|
||||||
|
BonusLuck = 0
|
||||||
|
BonusHP = 0
|
||||||
|
BonusVT = 0
|
||||||
|
AeolicResistance = 0
|
||||||
|
TelluricResistance = 0
|
||||||
|
HydricResistance = 0
|
||||||
|
IgneousResistance = 0
|
||||||
|
FerrumResistance = 0
|
||||||
|
HolyResistance = 0
|
||||||
|
CurseResistance = 0
|
||||||
|
ThrowSpeed = 12.0
|
||||||
|
ThrowDamage = 5
|
||||||
|
ItemTag = 0
|
||||||
|
Texture = ExtResource("1_8mgq5")
|
||||||
@@ -13,11 +13,11 @@ _ferrumResistance = 0.0
|
|||||||
_holyResistance = 0.0
|
_holyResistance = 0.0
|
||||||
_curseResistance = 0.0
|
_curseResistance = 0.0
|
||||||
Name = "Ceremonial Vestments"
|
Name = "Ceremonial Vestments"
|
||||||
Description = "+2 DEF"
|
Description = "+1 DEF"
|
||||||
SpawnRate = 0.2
|
SpawnRate = 0.2
|
||||||
BonusAttack = 0
|
BonusAttack = 0
|
||||||
BonusDefense = 2
|
BonusDefense = 1
|
||||||
BonusLuck = 0.05
|
BonusLuck = 5
|
||||||
BonusHP = 0
|
BonusHP = 0
|
||||||
BonusVT = 0
|
BonusVT = 0
|
||||||
AeolicResistance = 0
|
AeolicResistance = 0
|
||||||
|
|||||||
33
Zennysoft.Game.Ma/src/items/armor/resources/Commitment.tres
Normal file
33
Zennysoft.Game.Ma/src/items/armor/resources/Commitment.tres
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
[gd_resource type="Resource" script_class="ArmorStats" load_steps=3 format=3 uid="uid://vqnffib54d6w"]
|
||||||
|
|
||||||
|
[ext_resource type="Texture2D" uid="uid://bhhxd7cphx0q2" path="res://src/items/armor/textures/Atoner's Adornments.png" id="1_cbdby"]
|
||||||
|
[ext_resource type="Script" uid="uid://dqtp6ewvttoyu" path="res://src/items/armor/ArmorStats.cs" id="2_1at28"]
|
||||||
|
|
||||||
|
[resource]
|
||||||
|
script = ExtResource("2_1at28")
|
||||||
|
_telluricResistance = 0.0
|
||||||
|
_aeolicResistance = 0.0
|
||||||
|
_hydricResistance = 0.0
|
||||||
|
_igneousResistance = 0.0
|
||||||
|
_ferrumResistance = 0.0
|
||||||
|
_holyResistance = 0.0
|
||||||
|
_curseResistance = 0.0
|
||||||
|
Name = "Commitment"
|
||||||
|
Description = "Armor cannot pass beyond current floor once equipped."
|
||||||
|
SpawnRate = 0.25
|
||||||
|
BonusAttack = 0
|
||||||
|
BonusDefense = 8
|
||||||
|
BonusLuck = 0.05
|
||||||
|
BonusHP = 0
|
||||||
|
BonusVT = 0
|
||||||
|
AeolicResistance = 0
|
||||||
|
TelluricResistance = 0
|
||||||
|
HydricResistance = 0
|
||||||
|
IgneousResistance = 0
|
||||||
|
FerrumResistance = 0
|
||||||
|
HolyResistance = 0
|
||||||
|
CurseResistance = 0
|
||||||
|
ThrowSpeed = 12.0
|
||||||
|
ThrowDamage = 5
|
||||||
|
ItemTag = 1
|
||||||
|
Texture = ExtResource("1_cbdby")
|
||||||
@@ -16,7 +16,7 @@ Name = "Gift of Grace"
|
|||||||
Description = "Raises VT by 25."
|
Description = "Raises VT by 25."
|
||||||
SpawnRate = 0.5
|
SpawnRate = 0.5
|
||||||
BonusAttack = 0
|
BonusAttack = 0
|
||||||
BonusDefense = 3
|
BonusDefense = 7
|
||||||
BonusLuck = 0
|
BonusLuck = 0
|
||||||
BonusHP = 0
|
BonusHP = 0
|
||||||
BonusVT = 25
|
BonusVT = 25
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
[gd_scene load_steps=8 format=3 uid="uid://bgln7hdyyk34r"]
|
[gd_scene load_steps=8 format=3 uid="uid://bgln7hdyyk34r"]
|
||||||
|
|
||||||
[ext_resource type="Script" uid="uid://c2sps6uamyyw2" path="res://src/items/dropped/DroppedItem.cs" id="1_67jk4"]
|
[ext_resource type="Script" uid="uid://c2sps6uamyyw2" path="res://src/items/dropped/DroppedItem.cs" id="1_67jk4"]
|
||||||
|
[ext_resource type="Texture2D" uid="uid://bhhxd7cphx0q2" path="res://src/items/armor/textures/Atoner's Adornments.png" id="2_x5q15"]
|
||||||
|
|
||||||
[sub_resource type="SphereShape3D" id="SphereShape3D_28r8g"]
|
[sub_resource type="SphereShape3D" id="SphereShape3D_28r8g"]
|
||||||
|
|
||||||
@@ -45,9 +46,6 @@ _data = {
|
|||||||
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_eat5q"]
|
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_eat5q"]
|
||||||
radius = 0.47
|
radius = 0.47
|
||||||
|
|
||||||
[sub_resource type="ViewportTexture" id="ViewportTexture_x5q15"]
|
|
||||||
viewport_path = NodePath("Sprite3D/SubViewportContainer/SubViewport")
|
|
||||||
|
|
||||||
[node name="DroppedItem" type="RigidBody3D"]
|
[node name="DroppedItem" type="RigidBody3D"]
|
||||||
process_mode = 1
|
process_mode = 1
|
||||||
collision_layer = 1024
|
collision_layer = 1024
|
||||||
@@ -77,18 +75,14 @@ collision_mask = 0
|
|||||||
shape = SubResource("CapsuleShape3D_eat5q")
|
shape = SubResource("CapsuleShape3D_eat5q")
|
||||||
|
|
||||||
[node name="Sprite3D" type="Sprite3D" parent="."]
|
[node name="Sprite3D" type="Sprite3D" parent="."]
|
||||||
pixel_size = 0.025
|
pixel_size = 0.005
|
||||||
billboard = 2
|
billboard = 2
|
||||||
texture_filter = 0
|
texture_filter = 0
|
||||||
texture = SubResource("ViewportTexture_x5q15")
|
|
||||||
|
|
||||||
[node name="SubViewportContainer" type="SubViewportContainer" parent="Sprite3D"]
|
[node name="SubViewportContainer" type="SubViewportContainer" parent="Sprite3D"]
|
||||||
visibility_layer = 0
|
visibility_layer = 0
|
||||||
anchors_preset = 15
|
offset_right = 125.0
|
||||||
anchor_right = 1.0
|
offset_bottom = 125.0
|
||||||
anchor_bottom = 1.0
|
|
||||||
grow_horizontal = 2
|
|
||||||
grow_vertical = 2
|
|
||||||
size_flags_horizontal = 3
|
size_flags_horizontal = 3
|
||||||
size_flags_vertical = 3
|
size_flags_vertical = 3
|
||||||
|
|
||||||
@@ -97,10 +91,11 @@ transparent_bg = true
|
|||||||
handle_input_locally = false
|
handle_input_locally = false
|
||||||
canvas_item_default_texture_filter = 0
|
canvas_item_default_texture_filter = 0
|
||||||
canvas_cull_mask = 4293918721
|
canvas_cull_mask = 4293918721
|
||||||
size = Vector2i(30, 30)
|
size = Vector2i(128, 128)
|
||||||
render_target_update_mode = 4
|
render_target_update_mode = 4
|
||||||
|
|
||||||
[node name="Sprite" type="Sprite2D" parent="Sprite3D/SubViewportContainer/SubViewport"]
|
[node name="Sprite" type="Sprite2D" parent="Sprite3D/SubViewportContainer/SubViewport"]
|
||||||
unique_name_in_owner = true
|
unique_name_in_owner = true
|
||||||
texture_filter = 1
|
texture_filter = 1
|
||||||
offset = Vector2(15, 15)
|
texture = ExtResource("2_x5q15")
|
||||||
|
offset = Vector2(64, 64)
|
||||||
|
|||||||
@@ -395,6 +395,8 @@ public partial class Player : CharacterBody3D, IPlayer, IProvide<IPlayer>
|
|||||||
Inventory.Remove(weapon);
|
Inventory.Remove(weapon);
|
||||||
break;
|
break;
|
||||||
case JewelTags.Glue:
|
case JewelTags.Glue:
|
||||||
|
if (!EquipmentComponent.IsItemEquipped(weapon))
|
||||||
|
break;
|
||||||
weapon.Glued = true;
|
weapon.Glued = true;
|
||||||
weapon.Augment = new Augment(JewelTags.Glue, new BasicAugment());
|
weapon.Augment = new Augment(JewelTags.Glue, new BasicAugment());
|
||||||
break;
|
break;
|
||||||
@@ -449,6 +451,8 @@ public partial class Player : CharacterBody3D, IPlayer, IProvide<IPlayer>
|
|||||||
Inventory.Remove(armor);
|
Inventory.Remove(armor);
|
||||||
break;
|
break;
|
||||||
case JewelTags.Glue:
|
case JewelTags.Glue:
|
||||||
|
if (!EquipmentComponent.IsItemEquipped(armor))
|
||||||
|
break;
|
||||||
armor.Glued = true;
|
armor.Glued = true;
|
||||||
armor.Augment = new Augment(JewelTags.Glue, new BasicAugment());
|
armor.Augment = new Augment(JewelTags.Glue, new BasicAugment());
|
||||||
break;
|
break;
|
||||||
@@ -503,6 +507,8 @@ public partial class Player : CharacterBody3D, IPlayer, IProvide<IPlayer>
|
|||||||
Inventory.Remove(accessory);
|
Inventory.Remove(accessory);
|
||||||
break;
|
break;
|
||||||
case JewelTags.Glue:
|
case JewelTags.Glue:
|
||||||
|
if (!EquipmentComponent.IsItemEquipped(accessory))
|
||||||
|
break;
|
||||||
accessory.Glued = true;
|
accessory.Glued = true;
|
||||||
accessory.Augment = new Augment(JewelTags.Glue, new BasicAugment());
|
accessory.Augment = new Augment(JewelTags.Glue, new BasicAugment());
|
||||||
break;
|
break;
|
||||||
|
|||||||
@@ -44,16 +44,17 @@ public partial class ActionPanel : Panel
|
|||||||
|
|
||||||
public void FocusActionPanel()
|
public void FocusActionPanel()
|
||||||
{
|
{
|
||||||
|
if (!InteractButton.Disabled)
|
||||||
InteractButton.GrabFocus();
|
InteractButton.GrabFocus();
|
||||||
|
else if (!ThrowButton.Disabled)
|
||||||
|
ThrowButton.GrabFocus();
|
||||||
|
else if (!DropButton.Disabled)
|
||||||
|
DropButton.GrabFocus();
|
||||||
}
|
}
|
||||||
|
|
||||||
public void HideActionPanel()
|
public void HideActionPanel()
|
||||||
{
|
{
|
||||||
InteractButton.Disabled = false;
|
ResetActionPanel();
|
||||||
ThrowButton.Disabled = false;
|
|
||||||
DropButton.Disabled = false;
|
|
||||||
ThrowButton.FocusMode = FocusModeEnum.All;
|
|
||||||
DropButton.FocusMode = FocusModeEnum.All;
|
|
||||||
ActionPanelClosing?.Invoke();
|
ActionPanelClosing?.Invoke();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -65,6 +66,18 @@ public partial class ActionPanel : Panel
|
|||||||
HideActionPanel();
|
HideActionPanel();
|
||||||
SfxDatabase.Instance.Play(SoundEffect.CancelUI);
|
SfxDatabase.Instance.Play(SoundEffect.CancelUI);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (Visible && Input.IsActionJustPressed(GameInputs.MoveUp) && ThrowButton.HasFocus() && !InteractButton.Disabled)
|
||||||
|
SfxDatabase.Instance.Play(SoundEffect.MoveUI);
|
||||||
|
|
||||||
|
if (Visible && Input.IsActionJustPressed(GameInputs.MoveUp) && DropButton.HasFocus() && !ThrowButton.Disabled)
|
||||||
|
SfxDatabase.Instance.Play(SoundEffect.MoveUI);
|
||||||
|
|
||||||
|
if (Visible && Input.IsActionJustPressed(GameInputs.MoveDown) && InteractButton.HasFocus() && !ThrowButton.Disabled)
|
||||||
|
SfxDatabase.Instance.Play(SoundEffect.MoveUI);
|
||||||
|
|
||||||
|
if (Visible && Input.IsActionJustPressed(GameInputs.MoveDown) && ThrowButton.HasFocus() && !DropButton.Disabled)
|
||||||
|
SfxDatabase.Instance.Play(SoundEffect.MoveUI);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void InteractButton_Pressed()
|
private void InteractButton_Pressed()
|
||||||
@@ -90,6 +103,7 @@ public partial class ActionPanel : Panel
|
|||||||
|
|
||||||
private void SetOptions(IBaseInventoryItem item)
|
private void SetOptions(IBaseInventoryItem item)
|
||||||
{
|
{
|
||||||
|
ResetActionPanel();
|
||||||
SetOptionsInternal((dynamic)item);
|
SetOptionsInternal((dynamic)item);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -98,17 +112,23 @@ public partial class ActionPanel : Panel
|
|||||||
InteractButton.Disabled = false;
|
InteractButton.Disabled = false;
|
||||||
ThrowButton.Disabled = false;
|
ThrowButton.Disabled = false;
|
||||||
DropButton.Disabled = false;
|
DropButton.Disabled = false;
|
||||||
|
InteractButton.FocusMode = FocusModeEnum.All;
|
||||||
ThrowButton.FocusMode = FocusModeEnum.All;
|
ThrowButton.FocusMode = FocusModeEnum.All;
|
||||||
DropButton.FocusMode = FocusModeEnum.All;
|
DropButton.FocusMode = FocusModeEnum.All;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void SetOptionsInternal(IEquipableItem equipable)
|
private void SetOptionsInternal(IEquipableItem equipable)
|
||||||
{
|
{
|
||||||
|
var glued = false;
|
||||||
|
glued = CheckIfCurrentlyEquippedItemIsGlued(equipable, glued);
|
||||||
|
|
||||||
var isItemEquipped = _player.EquipmentComponent.IsItemEquipped(equipable);
|
var isItemEquipped = _player.EquipmentComponent.IsItemEquipped(equipable);
|
||||||
|
|
||||||
InteractButton.Text = isItemEquipped ? "Unequip" : "Equip";
|
InteractButton.Text = isItemEquipped ? "Unequip" : "Equip";
|
||||||
InteractButton.Disabled = equipable.Glued;
|
InteractButton.Disabled = glued;
|
||||||
ThrowButton.Disabled = equipable.Glued || isItemEquipped;
|
ThrowButton.Disabled = equipable.Glued || isItemEquipped;
|
||||||
DropButton.Disabled = equipable.Glued || isItemEquipped;
|
DropButton.Disabled = equipable.Glued || isItemEquipped;
|
||||||
|
InteractButton.FocusMode = InteractButton.Disabled ? FocusModeEnum.None : FocusModeEnum.All;
|
||||||
ThrowButton.FocusMode = ThrowButton.Disabled ? FocusModeEnum.None : FocusModeEnum.All;
|
ThrowButton.FocusMode = ThrowButton.Disabled ? FocusModeEnum.None : FocusModeEnum.All;
|
||||||
DropButton.FocusMode = DropButton.Disabled ? FocusModeEnum.None : FocusModeEnum.All;
|
DropButton.FocusMode = DropButton.Disabled ? FocusModeEnum.None : FocusModeEnum.All;
|
||||||
}
|
}
|
||||||
@@ -163,4 +183,14 @@ public partial class ActionPanel : Panel
|
|||||||
_currentlySelected = null;
|
_currentlySelected = null;
|
||||||
ActionPanelClosing?.Invoke();
|
ActionPanelClosing?.Invoke();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private bool CheckIfCurrentlyEquippedItemIsGlued(IEquipableItem equipable, bool glued)
|
||||||
|
{
|
||||||
|
if ((equipable is Weapon && _player.EquipmentComponent.EquippedWeapon.Value != null && _player.EquipmentComponent.EquippedWeapon.Value.Glued) ||
|
||||||
|
(equipable is Armor && _player.EquipmentComponent.EquippedArmor.Value != null && _player.EquipmentComponent.EquippedArmor.Value.Glued) ||
|
||||||
|
(equipable is Accessory && _player.EquipmentComponent.EquippedAccessory.Value != null && _player.EquipmentComponent.EquippedAccessory.Value.Glued) ||
|
||||||
|
(equipable is Ammo && _player.EquipmentComponent.EquippedAmmo.Value != null && _player.EquipmentComponent.EquippedAmmo.Value.Glued))
|
||||||
|
glued = true;
|
||||||
|
return glued;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -37,6 +37,7 @@ public partial class AugmentableItemsMenu : Control
|
|||||||
ItemSlots.ForEach(x => x.ItemSelected += ItemSelected);
|
ItemSlots.ForEach(x => x.ItemSelected += ItemSelected);
|
||||||
CancelAugmentButton.Pressed += CancelAugmentButton_Pressed;
|
CancelAugmentButton.Pressed += CancelAugmentButton_Pressed;
|
||||||
ConfirmAugmentButton.Pressed += ConfirmAugmentButton_Pressed;
|
ConfirmAugmentButton.Pressed += ConfirmAugmentButton_Pressed;
|
||||||
|
Hide();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void ConfirmAugmentButton_Pressed()
|
private void ConfirmAugmentButton_Pressed()
|
||||||
@@ -54,6 +55,8 @@ public partial class AugmentableItemsMenu : Control
|
|||||||
|
|
||||||
private void CloseAugmentMenu()
|
private void CloseAugmentMenu()
|
||||||
{
|
{
|
||||||
|
foreach (var item in ItemSlots)
|
||||||
|
item.SetEmpty();
|
||||||
SfxDatabase.Instance.Play(SoundEffect.CancelUI);
|
SfxDatabase.Instance.Play(SoundEffect.CancelUI);
|
||||||
ConfirmAugmentContainer.Hide();
|
ConfirmAugmentContainer.Hide();
|
||||||
AugmentMenuClosing?.Invoke();
|
AugmentMenuClosing?.Invoke();
|
||||||
@@ -64,17 +67,18 @@ public partial class AugmentableItemsMenu : Control
|
|||||||
_augmentingItem = augmentingItem;
|
_augmentingItem = augmentingItem;
|
||||||
|
|
||||||
var inventory = _player.Inventory.Items;
|
var inventory = _player.Inventory.Items;
|
||||||
|
var validSelectableItems = inventory.Except(inventory.OfType<IEquipableItem>().Where(x => x.Glued)).ToList();
|
||||||
ItemSlots.ForEach(x => x.SetEmpty());
|
ItemSlots.ForEach(x => x.SetEmpty());
|
||||||
var slotIndex = 0;
|
var slotIndex = 0;
|
||||||
|
|
||||||
foreach (var item in inventory)
|
foreach (var item in validSelectableItems)
|
||||||
{
|
{
|
||||||
if (item is IAugmentableItem augmentable && augmentable.Augment == null)
|
if (item is IAugmentableItem augmentable && augmentable.Augment == null)
|
||||||
ItemSlots[slotIndex++].SetItemToSlot(item);
|
ItemSlots[slotIndex++].SetItemToSlot(item);
|
||||||
}
|
}
|
||||||
|
|
||||||
Show();
|
Show();
|
||||||
ItemSlots.First().FocusItem();
|
ItemSlots.First(x => x.Item.Value == validSelectableItems.First()).FocusItem();
|
||||||
}
|
}
|
||||||
|
|
||||||
public override void _Input(InputEvent @event)
|
public override void _Input(InputEvent @event)
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
[gd_scene load_steps=16 format=3 uid="uid://tpqh7q0xh63c"]
|
[gd_scene load_steps=18 format=3 uid="uid://tpqh7q0xh63c"]
|
||||||
|
|
||||||
[ext_resource type="PackedScene" uid="uid://c005nd0m2eim" path="res://src/ui/inventory_menu/ItemSlot.tscn" id="1_a5r0f"]
|
[ext_resource type="PackedScene" uid="uid://c005nd0m2eim" path="res://src/ui/inventory_menu/ItemSlot.tscn" id="1_a5r0f"]
|
||||||
[ext_resource type="Script" uid="uid://brtic4hw6thox" path="res://src/ui/inventory_menu/AugmentableItemsMenu.cs" id="1_ukqf2"]
|
[ext_resource type="Script" uid="uid://brtic4hw6thox" path="res://src/ui/inventory_menu/AugmentableItemsMenu.cs" id="1_ukqf2"]
|
||||||
@@ -8,8 +8,12 @@
|
|||||||
[ext_resource type="StyleBox" uid="uid://bl15q835s4ene" path="res://src/options/UnselectedOptionsBox.tres" id="5_rxojm"]
|
[ext_resource type="StyleBox" uid="uid://bl15q835s4ene" path="res://src/options/UnselectedOptionsBox.tres" id="5_rxojm"]
|
||||||
[ext_resource type="LabelSettings" uid="uid://b6f8ggy3ulonb" path="res://src/ui/label_settings/GeorgiaItalic.tres" id="7_qtvkp"]
|
[ext_resource type="LabelSettings" uid="uid://b6f8ggy3ulonb" path="res://src/ui/label_settings/GeorgiaItalic.tres" id="7_qtvkp"]
|
||||||
|
|
||||||
|
[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_qtvkp"]
|
||||||
|
|
||||||
[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_l0byb"]
|
[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_l0byb"]
|
||||||
|
|
||||||
|
[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_p84pf"]
|
||||||
|
|
||||||
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_7co7g"]
|
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_7co7g"]
|
||||||
bg_color = Color(0, 0, 0, 0.745098)
|
bg_color = Color(0, 0, 0, 0.745098)
|
||||||
|
|
||||||
@@ -38,40 +42,48 @@ font_size = 40
|
|||||||
outline_size = 3
|
outline_size = 3
|
||||||
outline_color = Color(0, 0, 0, 1)
|
outline_color = Color(0, 0, 0, 1)
|
||||||
|
|
||||||
[node name="AugmentMenu" type="Panel"]
|
[node name="PanelContainer" type="PanelContainer"]
|
||||||
anchors_preset = 15
|
anchors_preset = 15
|
||||||
anchor_right = 1.0
|
anchor_right = 1.0
|
||||||
anchor_bottom = 1.0
|
anchor_bottom = 1.0
|
||||||
grow_horizontal = 2
|
grow_horizontal = 2
|
||||||
grow_vertical = 2
|
grow_vertical = 2
|
||||||
mouse_filter = 2
|
theme_override_styles/panel = SubResource("StyleBoxEmpty_qtvkp")
|
||||||
theme_override_styles/panel = SubResource("StyleBoxEmpty_l0byb")
|
|
||||||
script = ExtResource("1_ukqf2")
|
script = ExtResource("1_ukqf2")
|
||||||
|
|
||||||
[node name="CenterContainer2" type="CenterContainer" parent="."]
|
[node name="AugmentMenu" type="Panel" parent="."]
|
||||||
layout_mode = 1
|
layout_mode = 2
|
||||||
anchors_preset = 8
|
mouse_filter = 2
|
||||||
anchor_left = 0.5
|
theme_override_styles/panel = SubResource("StyleBoxEmpty_l0byb")
|
||||||
anchor_top = 0.5
|
|
||||||
anchor_right = 0.5
|
|
||||||
anchor_bottom = 0.5
|
|
||||||
offset_left = -400.0
|
|
||||||
offset_top = -512.5
|
|
||||||
offset_right = 400.0
|
|
||||||
offset_bottom = 512.5
|
|
||||||
grow_horizontal = 2
|
|
||||||
grow_vertical = 2
|
|
||||||
|
|
||||||
[node name="AugmentableItemsList" type="PanelContainer" parent="CenterContainer2"]
|
[node name="CenterContainer2" type="PanelContainer" parent="AugmentMenu"]
|
||||||
|
layout_mode = 1
|
||||||
|
anchors_preset = 11
|
||||||
|
anchor_left = 1.0
|
||||||
|
anchor_right = 1.0
|
||||||
|
anchor_bottom = 1.0
|
||||||
|
offset_left = -860.0
|
||||||
|
offset_bottom = -105.0
|
||||||
|
grow_horizontal = 0
|
||||||
|
grow_vertical = 2
|
||||||
|
theme_override_styles/panel = SubResource("StyleBoxEmpty_p84pf")
|
||||||
|
|
||||||
|
[node name="MarginContainer" type="MarginContainer" parent="AugmentMenu/CenterContainer2"]
|
||||||
|
layout_mode = 2
|
||||||
|
theme_override_constants/margin_left = 60
|
||||||
|
theme_override_constants/margin_top = 60
|
||||||
|
theme_override_constants/margin_right = 60
|
||||||
|
|
||||||
|
[node name="AugmentableItemsList" type="PanelContainer" parent="AugmentMenu/CenterContainer2/MarginContainer"]
|
||||||
unique_name_in_owner = true
|
unique_name_in_owner = true
|
||||||
custom_minimum_size = Vector2(800, 975)
|
custom_minimum_size = Vector2(800, 975)
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="Panel" type="Panel" parent="CenterContainer2/AugmentableItemsList"]
|
[node name="Panel" type="Panel" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList"]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
theme_override_styles/panel = SubResource("StyleBoxFlat_7co7g")
|
theme_override_styles/panel = SubResource("StyleBoxFlat_7co7g")
|
||||||
|
|
||||||
[node name="MarginContainer" type="MarginContainer" parent="CenterContainer2/AugmentableItemsList/Panel"]
|
[node name="MarginContainer" type="MarginContainer" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel"]
|
||||||
layout_mode = 1
|
layout_mode = 1
|
||||||
anchors_preset = 15
|
anchors_preset = 15
|
||||||
anchor_right = 1.0
|
anchor_right = 1.0
|
||||||
@@ -83,12 +95,12 @@ theme_override_constants/margin_top = 5
|
|||||||
theme_override_constants/margin_right = 5
|
theme_override_constants/margin_right = 5
|
||||||
theme_override_constants/margin_bottom = 5
|
theme_override_constants/margin_bottom = 5
|
||||||
|
|
||||||
[node name="ReferenceRect" type="ReferenceRect" parent="CenterContainer2/AugmentableItemsList/Panel/MarginContainer"]
|
[node name="ReferenceRect" type="ReferenceRect" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel/MarginContainer"]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
border_color = Color(1, 1, 1, 1)
|
border_color = Color(1, 1, 1, 1)
|
||||||
editor_only = false
|
editor_only = false
|
||||||
|
|
||||||
[node name="MarginContainer2" type="MarginContainer" parent="CenterContainer2/AugmentableItemsList/Panel"]
|
[node name="MarginContainer2" type="MarginContainer" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel"]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
offset_right = 800.0
|
offset_right = 800.0
|
||||||
offset_bottom = 1050.0
|
offset_bottom = 1050.0
|
||||||
@@ -97,86 +109,86 @@ theme_override_constants/margin_top = 15
|
|||||||
theme_override_constants/margin_right = 25
|
theme_override_constants/margin_right = 25
|
||||||
theme_override_constants/margin_bottom = 15
|
theme_override_constants/margin_bottom = 15
|
||||||
|
|
||||||
[node name="Inventory" type="VBoxContainer" parent="CenterContainer2/AugmentableItemsList/Panel/MarginContainer2"]
|
[node name="Inventory" type="VBoxContainer" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel/MarginContainer2"]
|
||||||
unique_name_in_owner = true
|
unique_name_in_owner = true
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
size_flags_vertical = 0
|
size_flags_vertical = 0
|
||||||
theme_override_constants/separation = 0
|
theme_override_constants/separation = 0
|
||||||
|
|
||||||
[node name="AugmentableSlot" parent="CenterContainer2/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
[node name="AugmentableSlot" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="AugmentableSlot2" parent="CenterContainer2/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
[node name="AugmentableSlot2" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="AugmentableSlot3" parent="CenterContainer2/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
[node name="AugmentableSlot3" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="AugmentableSlot4" parent="CenterContainer2/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
[node name="AugmentableSlot4" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="AugmentableSlot5" parent="CenterContainer2/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
[node name="AugmentableSlot5" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="AugmentableSlot6" parent="CenterContainer2/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
[node name="AugmentableSlot6" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="AugmentableSlot7" parent="CenterContainer2/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
[node name="AugmentableSlot7" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="AugmentableSlot8" parent="CenterContainer2/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
[node name="AugmentableSlot8" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="AugmentableSlot9" parent="CenterContainer2/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
[node name="AugmentableSlot9" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="AugmentableSlot10" parent="CenterContainer2/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
[node name="AugmentableSlot10" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="AugmentableSlot11" parent="CenterContainer2/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
[node name="AugmentableSlot11" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="AugmentableSlot12" parent="CenterContainer2/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
[node name="AugmentableSlot12" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="AugmentableSlot13" parent="CenterContainer2/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
[node name="AugmentableSlot13" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="AugmentableSlot14" parent="CenterContainer2/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
[node name="AugmentableSlot14" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="AugmentableSlot15" parent="CenterContainer2/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
[node name="AugmentableSlot15" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="AugmentableSlot16" parent="CenterContainer2/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
[node name="AugmentableSlot16" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="AugmentableSlot17" parent="CenterContainer2/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
[node name="AugmentableSlot17" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="AugmentableSlot18" parent="CenterContainer2/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
[node name="AugmentableSlot18" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="AugmentableSlot19" parent="CenterContainer2/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
[node name="AugmentableSlot19" parent="AugmentMenu/CenterContainer2/MarginContainer/AugmentableItemsList/Panel/MarginContainer2/Inventory" instance=ExtResource("1_a5r0f")]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="TitleContainer" type="MarginContainer" parent="."]
|
[node name="TitleContainer" type="MarginContainer" parent="AugmentMenu"]
|
||||||
layout_mode = 1
|
layout_mode = 1
|
||||||
offset_right = 450.0
|
offset_right = 450.0
|
||||||
offset_bottom = 160.0
|
offset_bottom = 160.0
|
||||||
theme_override_constants/margin_left = 50
|
theme_override_constants/margin_left = 50
|
||||||
theme_override_constants/margin_top = 60
|
theme_override_constants/margin_top = 60
|
||||||
|
|
||||||
[node name="TitlePanelContainer" type="PanelContainer" parent="TitleContainer"]
|
[node name="TitlePanelContainer" type="PanelContainer" parent="AugmentMenu/TitleContainer"]
|
||||||
custom_minimum_size = Vector2(400, 100)
|
custom_minimum_size = Vector2(400, 100)
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
theme_override_styles/panel = SubResource("StyleBoxEmpty_ukqf2")
|
theme_override_styles/panel = SubResource("StyleBoxEmpty_ukqf2")
|
||||||
|
|
||||||
[node name="AugmentTitlePanel" type="Panel" parent="TitleContainer/TitlePanelContainer"]
|
[node name="AugmentTitlePanel" type="Panel" parent="AugmentMenu/TitleContainer/TitlePanelContainer"]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
theme_override_styles/panel = SubResource("StyleBoxFlat_qtvkp")
|
theme_override_styles/panel = SubResource("StyleBoxFlat_qtvkp")
|
||||||
|
|
||||||
[node name="MarginContainer" type="MarginContainer" parent="TitleContainer/TitlePanelContainer/AugmentTitlePanel"]
|
[node name="MarginContainer" type="MarginContainer" parent="AugmentMenu/TitleContainer/TitlePanelContainer/AugmentTitlePanel"]
|
||||||
layout_mode = 1
|
layout_mode = 1
|
||||||
anchors_preset = 15
|
anchors_preset = 15
|
||||||
anchor_right = 1.0
|
anchor_right = 1.0
|
||||||
@@ -188,13 +200,13 @@ theme_override_constants/margin_top = 10
|
|||||||
theme_override_constants/margin_right = 10
|
theme_override_constants/margin_right = 10
|
||||||
theme_override_constants/margin_bottom = 10
|
theme_override_constants/margin_bottom = 10
|
||||||
|
|
||||||
[node name="ReferenceRect" type="ReferenceRect" parent="TitleContainer/TitlePanelContainer/AugmentTitlePanel/MarginContainer"]
|
[node name="ReferenceRect" type="ReferenceRect" parent="AugmentMenu/TitleContainer/TitlePanelContainer/AugmentTitlePanel/MarginContainer"]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
border_color = Color(1, 1, 1, 1)
|
border_color = Color(1, 1, 1, 1)
|
||||||
border_width = 2.0
|
border_width = 2.0
|
||||||
editor_only = false
|
editor_only = false
|
||||||
|
|
||||||
[node name="AugmentLabel" type="Label" parent="TitleContainer/TitlePanelContainer/AugmentTitlePanel/MarginContainer/ReferenceRect"]
|
[node name="AugmentLabel" type="Label" parent="AugmentMenu/TitleContainer/TitlePanelContainer/AugmentTitlePanel/MarginContainer/ReferenceRect"]
|
||||||
layout_mode = 1
|
layout_mode = 1
|
||||||
anchors_preset = 8
|
anchors_preset = 8
|
||||||
anchor_left = 0.5
|
anchor_left = 0.5
|
||||||
@@ -213,7 +225,7 @@ label_settings = SubResource("LabelSettings_p84pf")
|
|||||||
horizontal_alignment = 1
|
horizontal_alignment = 1
|
||||||
vertical_alignment = 1
|
vertical_alignment = 1
|
||||||
|
|
||||||
[node name="DescriptionContainer" type="MarginContainer" parent="."]
|
[node name="DescriptionContainer" type="MarginContainer" parent="AugmentMenu"]
|
||||||
layout_mode = 1
|
layout_mode = 1
|
||||||
anchors_preset = 4
|
anchors_preset = 4
|
||||||
anchor_top = 0.5
|
anchor_top = 0.5
|
||||||
@@ -224,36 +236,36 @@ offset_bottom = 150.0
|
|||||||
grow_vertical = 2
|
grow_vertical = 2
|
||||||
theme_override_constants/margin_left = 50
|
theme_override_constants/margin_left = 50
|
||||||
|
|
||||||
[node name="ItemDescriptionPanelContainer" type="PanelContainer" parent="DescriptionContainer"]
|
[node name="ItemDescriptionPanelContainer" type="PanelContainer" parent="AugmentMenu/DescriptionContainer"]
|
||||||
custom_minimum_size = Vector2(300, 300)
|
custom_minimum_size = Vector2(300, 300)
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="ItemDescriptionBox" type="Panel" parent="DescriptionContainer/ItemDescriptionPanelContainer"]
|
[node name="ItemDescriptionBox" type="Panel" parent="AugmentMenu/DescriptionContainer/ItemDescriptionPanelContainer"]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
theme_override_styles/panel = SubResource("StyleBoxFlat_p84pf")
|
theme_override_styles/panel = SubResource("StyleBoxFlat_p84pf")
|
||||||
|
|
||||||
[node name="MarginContainer" type="MarginContainer" parent="DescriptionContainer/ItemDescriptionPanelContainer"]
|
[node name="MarginContainer" type="MarginContainer" parent="AugmentMenu/DescriptionContainer/ItemDescriptionPanelContainer"]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
theme_override_constants/margin_left = 5
|
theme_override_constants/margin_left = 5
|
||||||
theme_override_constants/margin_top = 5
|
theme_override_constants/margin_top = 5
|
||||||
theme_override_constants/margin_right = 5
|
theme_override_constants/margin_right = 5
|
||||||
theme_override_constants/margin_bottom = 5
|
theme_override_constants/margin_bottom = 5
|
||||||
|
|
||||||
[node name="ReferenceRect" type="ReferenceRect" parent="DescriptionContainer/ItemDescriptionPanelContainer/MarginContainer"]
|
[node name="ReferenceRect" type="ReferenceRect" parent="AugmentMenu/DescriptionContainer/ItemDescriptionPanelContainer/MarginContainer"]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
border_color = Color(1, 1, 1, 1)
|
border_color = Color(1, 1, 1, 1)
|
||||||
border_width = 2.0
|
border_width = 2.0
|
||||||
editor_only = false
|
editor_only = false
|
||||||
|
|
||||||
[node name="CenterContainer" type="CenterContainer" parent="DescriptionContainer/ItemDescriptionPanelContainer"]
|
[node name="CenterContainer" type="CenterContainer" parent="AugmentMenu/DescriptionContainer/ItemDescriptionPanelContainer"]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="Label" type="Label" parent="DescriptionContainer/ItemDescriptionPanelContainer/CenterContainer"]
|
[node name="Label" type="Label" parent="AugmentMenu/DescriptionContainer/ItemDescriptionPanelContainer/CenterContainer"]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
text = "Select an item to augment."
|
text = "Select an item to augment."
|
||||||
label_settings = ExtResource("7_qtvkp")
|
label_settings = ExtResource("7_qtvkp")
|
||||||
|
|
||||||
[node name="ConfirmAugmentContainer" type="Panel" parent="."]
|
[node name="ConfirmAugmentContainer" type="Panel" parent="AugmentMenu"]
|
||||||
unique_name_in_owner = true
|
unique_name_in_owner = true
|
||||||
visible = false
|
visible = false
|
||||||
layout_mode = 1
|
layout_mode = 1
|
||||||
@@ -263,7 +275,7 @@ anchor_bottom = 1.0
|
|||||||
grow_horizontal = 2
|
grow_horizontal = 2
|
||||||
grow_vertical = 2
|
grow_vertical = 2
|
||||||
|
|
||||||
[node name="CenterContainer" type="CenterContainer" parent="ConfirmAugmentContainer"]
|
[node name="CenterContainer" type="CenterContainer" parent="AugmentMenu/ConfirmAugmentContainer"]
|
||||||
layout_mode = 1
|
layout_mode = 1
|
||||||
anchors_preset = 15
|
anchors_preset = 15
|
||||||
anchor_right = 1.0
|
anchor_right = 1.0
|
||||||
@@ -271,45 +283,45 @@ anchor_bottom = 1.0
|
|||||||
grow_horizontal = 2
|
grow_horizontal = 2
|
||||||
grow_vertical = 2
|
grow_vertical = 2
|
||||||
|
|
||||||
[node name="PanelContainer" type="PanelContainer" parent="ConfirmAugmentContainer/CenterContainer"]
|
[node name="PanelContainer" type="PanelContainer" parent="AugmentMenu/ConfirmAugmentContainer/CenterContainer"]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="Panel" type="Panel" parent="ConfirmAugmentContainer/CenterContainer/PanelContainer"]
|
[node name="Panel" type="Panel" parent="AugmentMenu/ConfirmAugmentContainer/CenterContainer/PanelContainer"]
|
||||||
custom_minimum_size = Vector2(400, 250)
|
custom_minimum_size = Vector2(400, 250)
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
theme_override_styles/panel = SubResource("StyleBoxFlat_unikd")
|
theme_override_styles/panel = SubResource("StyleBoxFlat_unikd")
|
||||||
|
|
||||||
[node name="MarginContainer" type="MarginContainer" parent="ConfirmAugmentContainer/CenterContainer/PanelContainer"]
|
[node name="MarginContainer" type="MarginContainer" parent="AugmentMenu/ConfirmAugmentContainer/CenterContainer/PanelContainer"]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
theme_override_constants/margin_left = 5
|
theme_override_constants/margin_left = 5
|
||||||
theme_override_constants/margin_top = 5
|
theme_override_constants/margin_top = 5
|
||||||
theme_override_constants/margin_right = 5
|
theme_override_constants/margin_right = 5
|
||||||
theme_override_constants/margin_bottom = 5
|
theme_override_constants/margin_bottom = 5
|
||||||
|
|
||||||
[node name="ReferenceRect" type="ReferenceRect" parent="ConfirmAugmentContainer/CenterContainer/PanelContainer/MarginContainer"]
|
[node name="ReferenceRect" type="ReferenceRect" parent="AugmentMenu/ConfirmAugmentContainer/CenterContainer/PanelContainer/MarginContainer"]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
border_color = Color(1, 1, 1, 1)
|
border_color = Color(1, 1, 1, 1)
|
||||||
editor_only = false
|
editor_only = false
|
||||||
|
|
||||||
[node name="CenterContainer" type="CenterContainer" parent="ConfirmAugmentContainer/CenterContainer/PanelContainer"]
|
[node name="CenterContainer" type="CenterContainer" parent="AugmentMenu/ConfirmAugmentContainer/CenterContainer/PanelContainer"]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="VBoxContainer" type="VBoxContainer" parent="ConfirmAugmentContainer/CenterContainer/PanelContainer/CenterContainer"]
|
[node name="VBoxContainer" type="VBoxContainer" parent="AugmentMenu/ConfirmAugmentContainer/CenterContainer/PanelContainer/CenterContainer"]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
theme_override_constants/separation = 25
|
theme_override_constants/separation = 25
|
||||||
|
|
||||||
[node name="Label" type="Label" parent="ConfirmAugmentContainer/CenterContainer/PanelContainer/CenterContainer/VBoxContainer"]
|
[node name="Label" type="Label" parent="AugmentMenu/ConfirmAugmentContainer/CenterContainer/PanelContainer/CenterContainer/VBoxContainer"]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
text = "Augment Item?"
|
text = "Augment Item?"
|
||||||
label_settings = SubResource("LabelSettings_unikd")
|
label_settings = SubResource("LabelSettings_unikd")
|
||||||
horizontal_alignment = 1
|
horizontal_alignment = 1
|
||||||
|
|
||||||
[node name="HBoxContainer" type="HBoxContainer" parent="ConfirmAugmentContainer/CenterContainer/PanelContainer/CenterContainer/VBoxContainer"]
|
[node name="HBoxContainer" type="HBoxContainer" parent="AugmentMenu/ConfirmAugmentContainer/CenterContainer/PanelContainer/CenterContainer/VBoxContainer"]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
theme_override_constants/separation = 20
|
theme_override_constants/separation = 20
|
||||||
alignment = 1
|
alignment = 1
|
||||||
|
|
||||||
[node name="CancelAugmentButton" type="Button" parent="ConfirmAugmentContainer/CenterContainer/PanelContainer/CenterContainer/VBoxContainer/HBoxContainer"]
|
[node name="CancelAugmentButton" type="Button" parent="AugmentMenu/ConfirmAugmentContainer/CenterContainer/PanelContainer/CenterContainer/VBoxContainer/HBoxContainer"]
|
||||||
unique_name_in_owner = true
|
unique_name_in_owner = true
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
focus_neighbor_left = NodePath(".")
|
focus_neighbor_left = NodePath(".")
|
||||||
@@ -331,7 +343,7 @@ theme_override_styles/normal_mirrored = ExtResource("5_rxojm")
|
|||||||
theme_override_styles/normal = ExtResource("5_rxojm")
|
theme_override_styles/normal = ExtResource("5_rxojm")
|
||||||
text = "Cancel"
|
text = "Cancel"
|
||||||
|
|
||||||
[node name="ConfirmAugmentButton" type="Button" parent="ConfirmAugmentContainer/CenterContainer/PanelContainer/CenterContainer/VBoxContainer/HBoxContainer"]
|
[node name="ConfirmAugmentButton" type="Button" parent="AugmentMenu/ConfirmAugmentContainer/CenterContainer/PanelContainer/CenterContainer/VBoxContainer/HBoxContainer"]
|
||||||
unique_name_in_owner = true
|
unique_name_in_owner = true
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
focus_neighbor_left = NodePath("../CancelAugmentButton")
|
focus_neighbor_left = NodePath("../CancelAugmentButton")
|
||||||
|
|||||||
@@ -54,7 +54,6 @@ public partial class InventoryMenu : Control, IInventoryMenu
|
|||||||
ActionPanel.ReturnToGameAction += ActionPanel_ReturnToGameAction;
|
ActionPanel.ReturnToGameAction += ActionPanel_ReturnToGameAction;
|
||||||
ActionPanel.AugmentMenuRequested += ActionPanel_AugmentMenuRequested;
|
ActionPanel.AugmentMenuRequested += ActionPanel_AugmentMenuRequested;
|
||||||
AugmentMenu.AugmentMenuClosing += AugmentMenu_AugmentMenuClosing;
|
AugmentMenu.AugmentMenuClosing += AugmentMenu_AugmentMenuClosing;
|
||||||
AugmentMenu.FocusMode = FocusModeEnum.None;
|
|
||||||
_player.EquipmentComponent.EquipmentChanged += EquipmentChanged;
|
_player.EquipmentComponent.EquipmentChanged += EquipmentChanged;
|
||||||
_player.AttackComponent.CurrentAttack.Changed += AttackChanged;
|
_player.AttackComponent.CurrentAttack.Changed += AttackChanged;
|
||||||
_player.AttackComponent.MaximumAttack.Changed += AttackChanged;
|
_player.AttackComponent.MaximumAttack.Changed += AttackChanged;
|
||||||
@@ -79,9 +78,11 @@ public partial class InventoryMenu : Control, IInventoryMenu
|
|||||||
|
|
||||||
public override void _Input(InputEvent @event)
|
public override void _Input(InputEvent @event)
|
||||||
{
|
{
|
||||||
if (Input.IsActionJustPressed(GameInputs.MoveUp) && _currentlySelected != ItemSlots.First())
|
var validSelectableItems = _player.Inventory.Items.Except(_player.Inventory.Items.OfType<IEquipableItem>().Where(x => x.Glued)).ToList();
|
||||||
|
|
||||||
|
if (Input.IsActionJustPressed(GameInputs.MoveUp) && _currentlySelected.Item.Value != validSelectableItems.First())
|
||||||
SfxDatabase.Instance.Play(SoundEffect.MoveUI);
|
SfxDatabase.Instance.Play(SoundEffect.MoveUI);
|
||||||
if (Input.IsActionJustPressed(GameInputs.MoveDown) && _currentlySelected != ItemSlots.Last(x => x.Item.Value != null))
|
if (Input.IsActionJustPressed(GameInputs.MoveDown) && _currentlySelected.Item.Value != validSelectableItems.Last())
|
||||||
SfxDatabase.Instance.Play(SoundEffect.MoveUI);
|
SfxDatabase.Instance.Play(SoundEffect.MoveUI);
|
||||||
if (Input.IsActionJustPressed(GameInputs.Interact))
|
if (Input.IsActionJustPressed(GameInputs.Interact))
|
||||||
SfxDatabase.Instance.Play(SoundEffect.CancelUI);
|
SfxDatabase.Instance.Play(SoundEffect.CancelUI);
|
||||||
@@ -93,8 +94,6 @@ public partial class InventoryMenu : Control, IInventoryMenu
|
|||||||
ItemSlots.ForEach(x => x.ItemPressed -= ItemPressed);
|
ItemSlots.ForEach(x => x.ItemPressed -= ItemPressed);
|
||||||
ItemSlots.ForEach(x => x.ItemSelected -= ItemSelected);
|
ItemSlots.ForEach(x => x.ItemSelected -= ItemSelected);
|
||||||
MenuPanel.Hide();
|
MenuPanel.Hide();
|
||||||
MenuPanel.FocusMode = FocusModeEnum.None;
|
|
||||||
AugmentMenu.FocusMode = FocusModeEnum.All;
|
|
||||||
SetProcessInput(false);
|
SetProcessInput(false);
|
||||||
AugmentMenu.SetProcessInput(true);
|
AugmentMenu.SetProcessInput(true);
|
||||||
AugmentMenu.OpenAugmentMenu(_currentlySelected.Item.Value as IAugmentItem);
|
AugmentMenu.OpenAugmentMenu(_currentlySelected.Item.Value as IAugmentItem);
|
||||||
@@ -136,9 +135,7 @@ public partial class InventoryMenu : Control, IInventoryMenu
|
|||||||
_currentlySelected = null;
|
_currentlySelected = null;
|
||||||
|
|
||||||
if (_currentlySelected == null && validSelectableItems.Count > 0)
|
if (_currentlySelected == null && validSelectableItems.Count > 0)
|
||||||
{
|
|
||||||
_currentlySelected = ItemSlots.FirstOrDefault(x => x.Item.Value == validSelectableItems.First());
|
_currentlySelected = ItemSlots.FirstOrDefault(x => x.Item.Value == validSelectableItems.First());
|
||||||
}
|
|
||||||
|
|
||||||
if (validSelectableItems.Count > 0)
|
if (validSelectableItems.Count > 0)
|
||||||
_currentlySelected.FocusItem();
|
_currentlySelected.FocusItem();
|
||||||
@@ -167,8 +164,6 @@ public partial class InventoryMenu : Control, IInventoryMenu
|
|||||||
ItemSlots.ForEach(x => x.ItemPressed += ItemPressed);
|
ItemSlots.ForEach(x => x.ItemPressed += ItemPressed);
|
||||||
ItemSlots.ForEach(x => x.ItemSelected += ItemSelected);
|
ItemSlots.ForEach(x => x.ItemSelected += ItemSelected);
|
||||||
MenuPanel.Show();
|
MenuPanel.Show();
|
||||||
MenuPanel.FocusMode = FocusModeEnum.All;
|
|
||||||
AugmentMenu.FocusMode = FocusModeEnum.None;
|
|
||||||
SetProcessInput(true);
|
SetProcessInput(true);
|
||||||
AugmentMenu.SetProcessInput(false);
|
AugmentMenu.SetProcessInput(false);
|
||||||
AugmentMenu.Hide();
|
AugmentMenu.Hide();
|
||||||
|
|||||||
@@ -406,7 +406,7 @@ layout_mode = 2
|
|||||||
[node name="ItemSlot20" parent="Panel/MarginContainer/PanelContainer/MenuPanel/InventoryList/Panel/MarginContainer2/Inventory" instance=ExtResource("6_unikd")]
|
[node name="ItemSlot20" parent="Panel/MarginContainer/PanelContainer/MenuPanel/InventoryList/Panel/MarginContainer2/Inventory" instance=ExtResource("6_unikd")]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="AugmentMenu" parent="Panel/MarginContainer/PanelContainer" instance=ExtResource("6_xwkpe")]
|
[node name="AugmentMenu" parent="." instance=ExtResource("6_xwkpe")]
|
||||||
unique_name_in_owner = true
|
unique_name_in_owner = true
|
||||||
visible = false
|
visible = false
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|||||||
@@ -25,7 +25,7 @@ public partial class ItemSlot : Control, IItemSlot
|
|||||||
|
|
||||||
[Node] public Label ItemCountLabel { get; set; } = default!;
|
[Node] public Label ItemCountLabel { get; set; } = default!;
|
||||||
|
|
||||||
public AutoProp<IBaseInventoryItem> Item { get; } = new AutoProp<IBaseInventoryItem>(default);
|
public AutoProp<IBaseInventoryItem> Item { get; set; } = new AutoProp<IBaseInventoryItem>(default);
|
||||||
|
|
||||||
public event Action<IItemSlot> ItemPressed;
|
public event Action<IItemSlot> ItemPressed;
|
||||||
|
|
||||||
@@ -38,6 +38,8 @@ public partial class ItemSlot : Control, IItemSlot
|
|||||||
Item.Changed += Item_Changed;
|
Item.Changed += Item_Changed;
|
||||||
ItemName.Pressed += ItemSlot_Pressed;
|
ItemName.Pressed += ItemSlot_Pressed;
|
||||||
ItemName.FocusEntered += FocusItemInternal;
|
ItemName.FocusEntered += FocusItemInternal;
|
||||||
|
ItemName.Disabled = true;
|
||||||
|
ItemName.FocusMode = FocusModeEnum.None;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void SetItemToSlot(IBaseInventoryItem item)
|
public void SetItemToSlot(IBaseInventoryItem item)
|
||||||
@@ -45,6 +47,7 @@ public partial class ItemSlot : Control, IItemSlot
|
|||||||
Item.OnNext(item);
|
Item.OnNext(item);
|
||||||
ItemTexture.Texture = item.GetTexture();
|
ItemTexture.Texture = item.GetTexture();
|
||||||
ItemName.Disabled = false;
|
ItemName.Disabled = false;
|
||||||
|
ItemName.FocusMode = FocusModeEnum.All;
|
||||||
ItemName.Text = item.ItemName;
|
ItemName.Text = item.ItemName;
|
||||||
|
|
||||||
if (item is IStackable stackable)
|
if (item is IStackable stackable)
|
||||||
@@ -54,7 +57,7 @@ public partial class ItemSlot : Control, IItemSlot
|
|||||||
{
|
{
|
||||||
SetItemEquipmentStatus(_player.EquipmentComponent.IsItemEquipped(equipableItem));
|
SetItemEquipmentStatus(_player.EquipmentComponent.IsItemEquipped(equipableItem));
|
||||||
ItemName.Disabled = equipableItem.Glued;
|
ItemName.Disabled = equipableItem.Glued;
|
||||||
ItemName.FocusMode = ItemName.Disabled ? FocusModeEnum.None : FocusModeEnum.All;
|
ItemName.FocusMode = equipableItem.Glued ? FocusModeEnum.None : FocusModeEnum.All;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (item is IAugmentableItem augmentableItem)
|
if (item is IAugmentableItem augmentableItem)
|
||||||
@@ -67,8 +70,9 @@ public partial class ItemSlot : Control, IItemSlot
|
|||||||
{
|
{
|
||||||
Hide();
|
Hide();
|
||||||
ItemName.Disabled = true;
|
ItemName.Disabled = true;
|
||||||
|
ItemName.FocusMode = FocusModeEnum.None;
|
||||||
|
Item = new AutoProp<IBaseInventoryItem>(default);
|
||||||
ItemName.Text = string.Empty;
|
ItemName.Text = string.Empty;
|
||||||
Item.Clear();
|
|
||||||
ItemTexture.Texture = null;
|
ItemTexture.Texture = null;
|
||||||
SetItemEquipmentStatus(false);
|
SetItemEquipmentStatus(false);
|
||||||
SetAugmentStatus(false);
|
SetAugmentStatus(false);
|
||||||
@@ -110,12 +114,8 @@ public partial class ItemSlot : Control, IItemSlot
|
|||||||
private void Item_Changed(IBaseInventoryItem obj)
|
private void Item_Changed(IBaseInventoryItem obj)
|
||||||
{
|
{
|
||||||
if (obj == null)
|
if (obj == null)
|
||||||
return;
|
SetEmpty();
|
||||||
|
|
||||||
ItemName.Text = obj.ItemName;
|
SetItemToSlot(obj);
|
||||||
if (obj is IEquipableItem equipable)
|
|
||||||
SetItemEquipmentStatus(_player.EquipmentComponent.IsItemEquipped(equipable));
|
|
||||||
if (obj is IAugmentableItem augmentable)
|
|
||||||
SetAugmentStatus(augmentable.Augment != null);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user