mirror of
https://github.com/xivdev/Penumbra.git
synced 2026-01-03 06:13:45 +01:00
Fix some issues with customization IDs and supported counts.
This commit is contained in:
parent
47b5895404
commit
68b68d6ce7
4 changed files with 16 additions and 5 deletions
|
|
@ -5,6 +5,7 @@ using Penumbra.GameData.Data;
|
|||
using Penumbra.GameData.Enums;
|
||||
using Penumbra.GameData.Structs;
|
||||
using Penumbra.Interop.Structs;
|
||||
using Penumbra.Meta.Files;
|
||||
|
||||
namespace Penumbra.Meta.Manipulations;
|
||||
|
||||
|
|
@ -98,6 +99,12 @@ public readonly record struct ShpIdentifier(HumanSlot Slot, PrimaryId? Id, Shape
|
|||
if (Slot is HumanSlot.Unknown && Id is not null)
|
||||
return false;
|
||||
|
||||
if (Slot.ToSpecificEnum() is BodySlot && Id is { Id: > byte.MaxValue })
|
||||
return false;
|
||||
|
||||
if (Id is { Id: > ExpandedEqpGmpBase.Count - 1 })
|
||||
return false;
|
||||
|
||||
if (!ValidateCustomShapeString(Shape))
|
||||
return false;
|
||||
|
||||
|
|
|
|||
|
|
@ -70,7 +70,7 @@ public class ShapeManager : IRequiredService, IDisposable
|
|||
if (model is null || model->ModelResourceHandle is null)
|
||||
continue;
|
||||
|
||||
_ids[(int)modelIndex] = human.GetArmorChanged(modelIndex).Set;
|
||||
_ids[(int)modelIndex] = human.GetModelId(modelIndex);
|
||||
|
||||
ref var shapes = ref model->ModelResourceHandle->Shapes;
|
||||
foreach (var (shape, index) in shapes.Where(kvp => ShpIdentifier.ValidateCustomShapeString(kvp.Key.Value)))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue