From ef85534eeafe33153fb3860549bc52fc742ddb08 Mon Sep 17 00:00:00 2001 From: CatryBenoit Date: Thu, 17 Sep 2026 19:08:27 +0200 Subject: [PATCH] fix inventory --- Architecture_Projet.md | 10 +++++----- Content/Core/Character/SandboxCharacter_CMC.uasset | 4 ++-- Content/Core/Character/SandboxCharacter_Mover.uasset | 4 ++-- Content/Core/Coreinventory/ML_AGIS_UMG.uasset | 2 +- .../DataAssets/InventoryData/PlayerInventory.uasset | 4 ++-- Content/Maps/DevMap/MapDev1.umap | 4 ++-- .../Widgets/InventoryMenu/WB_InventoryPlayer.uasset | 4 ++-- .../Widgets/InventoryMenu/WB_InventoryScreen.uasset | 4 ++-- Content/UI/Inventory_UI/Widgets/WB_Container.uasset | 4 ++-- 9 files changed, 20 insertions(+), 20 deletions(-) diff --git a/Architecture_Projet.md b/Architecture_Projet.md index d8622e44..7bb9a668 100644 --- a/Architecture_Projet.md +++ b/Architecture_Projet.md @@ -390,7 +390,7 @@ Copie du framework "Sandbox Character" du sample Epic **Game Animation Sample**, ```text Content/Systems/Mover/ -├── SandboxCharacter_Mover.uasset → Personnage basé sur le plugin Mover. (Vérifié le 2026-09-15) `GM_Dev` (GameMode de `MapDev1`) a `DefaultPawnClass = SandboxCharacter_Mover` ; en PIE sur `MapDev1` le pion obtenu est `SandboxCharacter_Mover_Ragdoll`. `SetupInput` ajoute `Core/PlayerController/Input/IMC_Sandbox` (même IMC que le CMC, inputs AGIS/inventaire compris) ; il porte aussi `Inventory_Player`, dont la propriété `Input Mapping Context` DOIT valoir ce même `IMC_Sandbox` (corrigé le 2026-09-15, elle valait `IMC_AGIS_Character`) : à la fermeture de l'inventaire, `WB_InventoryScreen.SwitchInput` fait `ClearAllMappings` puis ne ré-ajoute QUE cette variable — une mauvaise valeur coupe tous les contrôles (ZQSD, caméra) après fermeture. Même piège pour tout futur pion équipé d'`Inventory_Player` +├── SandboxCharacter_Mover.uasset → Personnage basé sur le plugin Mover. (Vérifié le 2026-09-15) `GM_Dev` (GameMode de `MapDev1`) a `DefaultPawnClass = SandboxCharacter_Mover` ; en PIE sur `MapDev1` le pion obtenu est `SandboxCharacter_Mover_Ragdoll`. `SetupInput` ajoute `Core/PlayerController/Input/IMC_Sandbox` (même IMC que le CMC, inputs AGIS/inventaire compris) ; il porte aussi `Inventory_Player`, dont la propriété `Input Mapping Context` DOIT valoir ce même `IMC_Sandbox` (corrigé le 2026-09-15, elle valait `IMC_AGIS_Character`) : à la fermeture de l'inventaire, `WB_InventoryScreen.SwitchInput` fait `ClearAllMappings` puis ne ré-ajoute QUE cette variable — une mauvaise valeur coupe tous les contrôles (ZQSD, caméra) après fermeture. Même piège pour tout futur pion équipé d'`Inventory_Player`. Implémente `BPI_Interactable` depuis le 2026-09-17 (`GetTracePoint` = position/forward du composant `Camera`, comme `SandboxCharacter_CMC`) : sans cette interface, le trace d'interaction d'`Inventory_Player` (`Client Trace`, `Verify Trace`) part de (0,0,0) avec une direction nulle et aucun objet ne peut être ramassé. Tout futur pion équipé d'`Inventory_Player` doit aussi implémenter `BPI_Interactable::GetTracePoint` ├── SandboxCharacter_Mover_Ragdoll.uasset → Variante ragdoll du personnage Mover ├── SandboxCharacter_Mover_ABP.uasset → Anim Blueprint du Mover (utilise `Systems/Aiming/ABP_AimingMaster`) ├── GM_Sandbox.uasset / PC_Sandbox.uasset → GameMode (pawn = SandboxCharacter_Mover) et PlayerController du Mover ; création du widget de démo retirée le 2026-09-14 @@ -486,7 +486,7 @@ Content/Data/ ├── DataAssets/ │ ├── AttachmentData/ → AttachmentData (base) + AttachmentData_AdvancedRifle, AttachmentData_Flashlight : configuration des attachements d'armes │ ├── ContainerGroupData/ → Un DataAsset par "groupe de containers" (Backpack BIG/SMALL, Box/Chest Storage, Vest_1/2, ExampleStorage…) : définit la mise en page des slots d'un contenant - │ └── InventoryData/ → Un DataAsset par inventaire prédéfini (PlayerInventory, PlayerInventoryPart1/2, CardReader_Inventory, Generator_Inventory, Vehicle_Inventory). `PlayerInventory` (2026-09-16) = inventaire du JOUEUR : widget `WB_InventoryPlayer`, containers = les 12 de PlayerInventoryPart1 puis les 3 de PlayerInventoryPart2 (même ordre que `WB_InventoryPlayer::GetAllContainerWidgets`). `PlayerInventoryPart1/2` restent utilisés par les PNJ/cadavres fouillables (`BP_Deadman`, `BP_EnemyPuppet` → `WB_LootingHuman`) + │ └── InventoryData/ → Un DataAsset par inventaire prédéfini (PlayerInventory, PlayerInventoryPart1/2, CardReader_Inventory, Generator_Inventory, Vehicle_Inventory). `PlayerInventory` (2026-09-16) = inventaire du JOUEUR : widget `WB_InventoryPlayer`, containers = les 12 de PlayerInventoryPart1 puis les 3 de PlayerInventoryPart2 (même ordre que `WB_InventoryPlayer::GetAllContainerWidgets`) ; le container 12 (poches) est en 4×3 / 12 slots depuis le 2026-09-17 pour correspondre à `PocketContainer` (il était en 2×2 → seule la 1re ligne était utilisable ; `PlayerInventoryPart2`, utilisé par le pillage, a toujours ce défaut). `PlayerInventoryPart1/2` restent utilisés par les PNJ/cadavres fouillables (`BP_Deadman`, `BP_EnemyPuppet` → `WB_LootingHuman`) ├── Enumerations/ → Enums spécifiques AGIS : EAnimOverlayState, EBallDirections, EFourDirections/ETwoDirections, EInteractionType, EItemActions, ENestingRules, EPrintType, EReloadType, EServerVerificationType, ESlotAppearance, EVendorBuyOption └── Structures/ → Structs spécifiques AGIS ├── ItemDefaults.uasset → Struct CENTRALE décrivant un item (Name, etc.) — lue par WB_Item et par la logique de sélection rapide (Inventory_Player) @@ -507,14 +507,14 @@ Content/UI/ ├── Inventory_UI/ → TOUTE l'UI de l'inventaire (socle AGIS + ajouts projet) │ ├── MaterialResources/ → Matériaux/Material Instances de fond des slots (MI_Background_*, M_RuntimeItemMaterial…) │ └── Widgets/ -│ ├── WB_Container.uasset → Widget représentant un container (grille de slots) — contient SlotWidgets[] +│ ├── WB_Container.uasset → Widget représentant un container (grille de slots) — contient SlotWidgets[]. `CreateSlots` construit la grille d'après la `Container Size` DU WIDGET (les SlotInfo du DataAsset doivent avoir la même taille, sinon seules les premières cases sont utilisables). `GetParentEquipSlot` (corrigé le 2026-09-17) ne renvoie l'EquipSlot englobant (Outer.Outer) que si ce container EST son `Container` principal : les sous-containers d'un sac/gilet affichés ailleurs (sous les poches) gardent leur taille et leurs cases de 75 px au lieu d'être réduits à 1×1 en taille d'EquipSlot │ ├── WB_EquipSlot.uasset → Widget d'un slot d'équipement (arme/speed) — contient Container. Var `OwnContainersHost` (2026-09-04, typée `WB_InventoryPlayer` depuis 2026-09-16) : si définie, `OnContainerUpdate` ajoute les sous-containers de l'item équipé (ex. grille du sac à dos) dans ce widget via `AddContainerBelowPockets` au lieu de son propre `ContainersCanvas` interne. Câblée uniquement pour `EquipSlotBACKPACK` par `WB_InventoryScreen::InitializeWidgets`. │ ├── WB_InventorySlot.uasset → Widget d'un slot individuel dans une grille — expose "ItemWidget On Slot" │ ├── WB_Item.uasset → Widget représentant un item posé dans un slot — expose "Item Defaults" (struct ItemDefaults) │ │ │ ├── InventoryMenu/ -│ │ ├── WB_InventoryScreen.uasset → Widget racine de l'inventaire plein écran. Depuis 2026-09-16 contient un seul panneau joueur `Part2Box → OutlinePart2 → BackgroundPart2 → ScrollBox_0 → InventoryPlayer` (WB_InventoryPlayer : équipements + poches + sac à dos dans le même défilement) ; `InitializeWidgets` initialise `InventoryPlayer` et câble `EquipSlotBACKPACK.OwnContainersHost = InventoryPlayer`. `Inventory_Player::GetQuickSlotItemInfo` lit les slots WEAPON/WEAPON2/Speed1/Speed2 via `InventoryScreen.InventoryPlayer` -│ │ ├── WB_InventoryPlayer.uasset → (2026-09-16) Fusion de WB_InventoryPart1 + WB_InventoryPart2 pour l'inventaire du joueur, en un seul bloc continu : `EquipsVertical` → `EquipSlotsBox` (SizeBox 740×860) → `SlotsCanvas` avec les 12 EquipSlots, puis `VerticalBox_0` (titre Pockets + `PocketContainer`, et les containers du sac à dos ajoutés dessous par `Add Container Below Pockets`). `GetAllEquipSlots` = même ordre que Part1 ; `GetAllContainerWidgets` = containers des équipements puis PocketContainer. Données : DataAsset `PlayerInventory` +│ │ ├── WB_InventoryScreen.uasset → Widget racine de l'inventaire plein écran. Depuis 2026-09-16 contient un seul panneau joueur `Part2Box → OutlinePart2 → BackgroundPart2 → InventoryPlayer` (WB_InventoryPlayer : équipements à gauche, poches + sac à dos défilants à droite ; plus de ScrollBox extérieur depuis 2026-09-17, sinon la colonne de droite n'a pas de hauteur bornée) ; `InitializeWidgets` initialise `InventoryPlayer` et câble `EquipSlotBACKPACK.OwnContainersHost = InventoryPlayer`. `Inventory_Player::GetQuickSlotItemInfo` lit les slots WEAPON/WEAPON2/Speed1/Speed2 via `InventoryScreen.InventoryPlayer` +│ │ ├── WB_InventoryPlayer.uasset → (2026-09-16) Fusion de WB_InventoryPart1 + WB_InventoryPart2 pour l'inventaire du joueur, dans un seul cadre en deux colonnes (2026-09-17) : `EquipsVertical` → `ColumnsBox` (HorizontalBox, Fill) → [`EquipSlotsBox` (SizeBox 760×866) → `SlotsCanvas` avec les 12 EquipSlots] + [`PocketsScroll` (ScrollBox, barre visible) → `VerticalBox_0` (titre Pockets + `PocketContainer`, puis les containers du sac à dos ajoutés dessous par `Add Container Below Pockets`)]. `EquipSlotBACKPACK` et `EquipSlotVEST` ont `Item Containers Settings.ShowInventory = True` et `OwnContainersHost = InventoryPlayer` (câblé dans `WB_InventoryScreen::InitializeWidgets`) (défaut de WB_EquipSlot = False : sans ça, `OnContainerUpdate` ne crée jamais les grilles du sac). `GetAllEquipSlots` = même ordre que Part1 ; `GetAllContainerWidgets` = containers des équipements puis PocketContainer. Données : DataAsset `PlayerInventory` │ │ ├── WB_InventoryPart1.uasset → (utilisé seulement par WB_LootingHuman depuis 2026-09-16) Contient les 4 slots d'équipement (EquipSlotWEAPON, EquipSlotWEAPON2, EquipSlotSpeed1, EquipSlotSpeed2) + autres slots d'équipement (casque, gilet, gants, sac à dos…) │ │ └── WB_InventoryPart2.uasset → (utilisé seulement par WB_LootingHuman depuis 2026-09-16 ; sa fonction `Add Container Below Pockets` n'est plus appelée, WB_EquipSlot pointe désormais WB_InventoryPlayer) Grille(s) d'inventaire principale(s) (PocketContainer + titre, dans `VerticalBox_0`). Fonction `Add Container Below Pockets(Container)` (2026-09-04) : insère un WB_Container juste après le bloc Pockets (`PocketContainer.GetParent().GetParent()`) — utilisée par `WB_EquipSlot` (sac à dos) pour afficher ses slots supplémentaires sous les slots Pocket plutôt que dans son propre canvas. │ │ diff --git a/Content/Core/Character/SandboxCharacter_CMC.uasset b/Content/Core/Character/SandboxCharacter_CMC.uasset index 3fe2b08d..a6e8df10 100644 --- a/Content/Core/Character/SandboxCharacter_CMC.uasset +++ b/Content/Core/Character/SandboxCharacter_CMC.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dae8b9bd1ba77b439e685cdd4d05342ab407d1e0b54db8c22d27d5cb45430f58 -size 2961803 +oid sha256:a326af4e7d9f311f79f58c611219305cc37ed43841ecf42f9548fd53f9bfd98e +size 2961789 diff --git a/Content/Core/Character/SandboxCharacter_Mover.uasset b/Content/Core/Character/SandboxCharacter_Mover.uasset index a93f152d..55b76c81 100644 --- a/Content/Core/Character/SandboxCharacter_Mover.uasset +++ b/Content/Core/Character/SandboxCharacter_Mover.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d1c2df64944d94c805823d2d45b4cec441f819904289312ecb231b76b136a0df -size 2745596 +oid sha256:f414aacabb418e7cd567b18bcd9416261917a96a85606e2e049865f86800e924 +size 2759432 diff --git a/Content/Core/Coreinventory/ML_AGIS_UMG.uasset b/Content/Core/Coreinventory/ML_AGIS_UMG.uasset index a347cc70..1b6fd65e 100644 --- a/Content/Core/Coreinventory/ML_AGIS_UMG.uasset +++ b/Content/Core/Coreinventory/ML_AGIS_UMG.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:41d1320f98b27034ca106c073e1e9eb413ac42499f6d83412886e9eca555d843 +oid sha256:450cae851145f28b72d49a00074b106f0cd465de0b2598d4c3e9f76644161f0b size 137435 diff --git a/Content/Data/Inventory_Data/DataAssets/InventoryData/PlayerInventory.uasset b/Content/Data/Inventory_Data/DataAssets/InventoryData/PlayerInventory.uasset index bdd604e1..44533d3d 100644 --- a/Content/Data/Inventory_Data/DataAssets/InventoryData/PlayerInventory.uasset +++ b/Content/Data/Inventory_Data/DataAssets/InventoryData/PlayerInventory.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bfcf705ee217acb1d0f47acd1150b3e52abf02e5072e739772c1b531a40e1a76 -size 7410 +oid sha256:e050e01372d054ea21e01c6744a5270f964a59d23511abd653a6120a50884d3e +size 7706 diff --git a/Content/Maps/DevMap/MapDev1.umap b/Content/Maps/DevMap/MapDev1.umap index 498401d8..ce502df8 100644 --- a/Content/Maps/DevMap/MapDev1.umap +++ b/Content/Maps/DevMap/MapDev1.umap @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2066d6febf39091781cca1b09b074c1c573b2e7230a2c28fe1e1a8121c112651 -size 5106777 +oid sha256:9c6badfb2b9cef4a955e69b8b69753693285a2b462482ac8735dcff199ff28f0 +size 5107639 diff --git a/Content/UI/Inventory_UI/Widgets/InventoryMenu/WB_InventoryPlayer.uasset b/Content/UI/Inventory_UI/Widgets/InventoryMenu/WB_InventoryPlayer.uasset index 72048421..01b63c7c 100644 --- a/Content/UI/Inventory_UI/Widgets/InventoryMenu/WB_InventoryPlayer.uasset +++ b/Content/UI/Inventory_UI/Widgets/InventoryMenu/WB_InventoryPlayer.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:949f03081fe43879dfaf3c000d84bfe2af53c6789aed59c34ff38cf2469b0b20 -size 146552 +oid sha256:9386c35dd5493a3d00ef2c3c36478fbe8ef744914f7c7a29b3c91eaaa150cca6 +size 150236 diff --git a/Content/UI/Inventory_UI/Widgets/InventoryMenu/WB_InventoryScreen.uasset b/Content/UI/Inventory_UI/Widgets/InventoryMenu/WB_InventoryScreen.uasset index f2dcd9e5..346d0e81 100644 --- a/Content/UI/Inventory_UI/Widgets/InventoryMenu/WB_InventoryScreen.uasset +++ b/Content/UI/Inventory_UI/Widgets/InventoryMenu/WB_InventoryScreen.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8e2d832ebca5b556a22e11923f9c2baf839c2c92543195f1f18e60b2ab4a6738 -size 674204 +oid sha256:c9258ffea98a067acc6e12ed2491d2ae783910ee1ccc3149b30d5689ee7ab1cc +size 678607 diff --git a/Content/UI/Inventory_UI/Widgets/WB_Container.uasset b/Content/UI/Inventory_UI/Widgets/WB_Container.uasset index f59975ec..0c728996 100644 --- a/Content/UI/Inventory_UI/Widgets/WB_Container.uasset +++ b/Content/UI/Inventory_UI/Widgets/WB_Container.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:597bf29ff90c371813aaa58246d5f82bd2d30413167f54bc9db8cabd51756e77 -size 463245 +oid sha256:6e8b4622e5f81c3c76ac671970e6068f0959033309be0778dfe05af37a526ec8 +size 457616