From 7791876f073329a78aeffb8dba1947eb43edd850 Mon Sep 17 00:00:00 2001 From: miku-666 <74728189+NessieHax@users.noreply.github.com> Date: Thu, 15 Aug 2024 13:54:50 +0200 Subject: [PATCH] BlockBenchModel - Add export property to class 'Element' --- PCK-Studio/External/Format/BlockBenchModel.cs | 7 ++++--- PCK-Studio/Internal/SkinModelImporter.cs | 2 +- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/PCK-Studio/External/Format/BlockBenchModel.cs b/PCK-Studio/External/Format/BlockBenchModel.cs index c6c85e9d..798b7f9b 100644 --- a/PCK-Studio/External/Format/BlockBenchModel.cs +++ b/PCK-Studio/External/Format/BlockBenchModel.cs @@ -63,6 +63,10 @@ namespace PckStudio.External.Format [JsonProperty("locked")] internal bool Locked; + [DefaultValue(true)] + [JsonProperty("export", DefaultValueHandling = DefaultValueHandling.Ignore)] + internal bool Export { get; } = true; + [JsonProperty("inflate")] internal float Inflate; @@ -329,9 +333,6 @@ namespace PckStudio.External.Format [JsonProperty("model_identifier")] internal string ModelIdentifier { get; set; } = ""; - [JsonProperty("visible_box")] - internal int[] VisibleBox; - [JsonProperty("resolution")] internal TextureRes TextureResolution; diff --git a/PCK-Studio/Internal/SkinModelImporter.cs b/PCK-Studio/Internal/SkinModelImporter.cs index c6e5314e..62a2e5d7 100644 --- a/PCK-Studio/Internal/SkinModelImporter.cs +++ b/PCK-Studio/Internal/SkinModelImporter.cs @@ -140,7 +140,7 @@ namespace PckStudio.Internal private static void LoadElement(string boxType, Element element, ref SkinModelInfo modelInfo) { - if (element.Type != "cube" || !element.UseBoxUv || !element.IsVisibile) + if (element.Type != "cube" || !element.UseBoxUv || !element.Export) return; boxType = TryConvertToSkinBoxType(boxType);