1
0
mirror of https://github.com/GeyserMC/PackConverter.git synced 2025-12-19 14:59:21 +00:00

Allow converting item models manually

This commit is contained in:
Eclipse
2025-10-13 17:04:04 +00:00
parent b101069e0e
commit 0f7fdda61b

View File

@@ -59,8 +59,8 @@ import java.util.Collection;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
public class ModelConverter implements AssetExtractor<Model>, AssetConverter<Model, BedrockModel>, AssetCombiner<BedrockModel> { public record ModelConverter(boolean convertItemModels) implements AssetExtractor<Model>, AssetConverter<Model, BedrockModel>, AssetCombiner<BedrockModel> {
public static final ModelConverter INSTANCE = new ModelConverter(); public static final ModelConverter INSTANCE = new ModelConverter(false);
private static final String FORMAT_VERSION = "1.16.0"; private static final String FORMAT_VERSION = "1.16.0";
private static final String GEOMETRY_FORMAT = "geometry.%s"; private static final String GEOMETRY_FORMAT = "geometry.%s";
@@ -90,7 +90,7 @@ public class ModelConverter implements AssetExtractor<Model>, AssetConverter<Mod
context.debug("Converting model " + model.key().key() + ":" + value); context.debug("Converting model " + model.key().key() + ":" + value);
// TODO: Convert item models but save differently? // TODO: Convert item models but save differently?
if (value.startsWith("item/")) { if (value.startsWith("item/") && !convertItemModels) {
return null; return null;
} }