Added SkinArmorFlags classes

This commit is contained in:
MayNL
2026-05-11 18:10:06 -04:00
parent de98a9217e
commit ec04639928
8 changed files with 192 additions and 8 deletions

View File

@@ -123,7 +123,7 @@ namespace PckStudio.ModelSupport
SkinBOX ApplyOffset(SkinBOX box)
{
SkinPartOffset offset = skinModel.PartOffsets.FirstOrDefault(offset => offset.Type == (box.IsOverlayPart() ? box.GetBaseType() : box.Type));
return string.IsNullOrEmpty(offset.Type) ? box : new SkinBOX(box.Type, box.Pos - (Vector3.UnitY * offset.Value), box.Size, box.UV, box.ArmorMaskFlags, box.Mirror, box.Scale);
return string.IsNullOrEmpty(offset.Type) ? box : new SkinBOX(box.Type, box.Pos - (Vector3.UnitY * offset.Value), box.Size, box.UV, box.ArmorMaskFlags.ToValue(), box.Mirror, box.Scale);
}
IEnumerable<SkinBOX> convertedBoxes = boxes.Select(ApplyOffset);