chore: upgrading to v3 for json compression (#351)

* chore: upgrading to v3 for json compression

* adding local build step

* adding test for compress

* auto: generate
This commit is contained in:
Daan Verstraten
2025-06-02 21:17:32 +02:00
committed by GitHub
parent ca6239c35c
commit b957fc93e8
34 changed files with 302 additions and 311 deletions

View File

@@ -1,149 +1,134 @@
{
"$id": "blockception.minecraft.behavior.worldgen.jigsaw_structures.minecraft.jigsaw",
"type": "object",
"title": "Jigsaw",
"additionalProperties": false,
"required": [
"description",
"max_depth",
"start_height",
"start_pool",
"step"
],
"properties": {
"biome_filters": {
"title": "Biome Filters",
"description": "Specifies the biomes in which the Jigsaw Structure can generate.",
"$ref": "../../../entities/filters/filters.json"
},
"description": {
"title": "Description",
"description": "The description of this jigsaw.",
"type": "object",
"additionalProperties": false,
"required": [ "identifier" ],
"properties": {
"identifier": {
"title": "Identifier",
"description": "Identifier of the Jigsaw Structure. This is used with commands such as /locate, as well as within Structure Set definitions to specify which Jigsaw Structures are included in a given set.",
"type": "string"
}
}
},
"heightmap_projection": {
"title": "Heightmap Projection",
"description": "Heightmap used to calculate the relative start height. For example, a heightmap_projection of ocean_floor and a start_height of 10 means the Jigsaw Structure will begin generating 10 blocks above the ocean floor.",
"type": "string",
"enum": [
"ocean_floor",
"world_surface"
]
},
"max_depth": {
"title": "Max Depth",
"type": "integer",
"description": " The maximum recursion depth for Jigsaw Structure Generation. For example, a Jigsaw Structure that builds a road with a max_depth of 5 will only have paths that are a maximum of 5 structures templates in length in any given direction from the origin.",
"minimum": 0.0,
"maximum": 20.0
},
"start_height": {
"title": "Start Height",
"description": "Height at which the Jigsaw Structure's start_pool should begin.",
"$ref": "./height_provider.json"
},
"start_pool": {
"title": "Start Pool",
"type": "string",
"description": "The first Template Pool to use when generating the Jigsaw Structure."
},
"start_jigsaw_name": {
"title": "Start Jigsaw Name",
"description": "The name of the Jigsaw Block from the start_pool to be placed first.",
"type": "string"
},
"max_distance_from_center": {
"title": "Max Distance From Center",
"description": "The max distance from the jigsaw pieces to the structure start.",
"type": "integer",
"minimum": 1,
"maximum": 128
},
"pool_aliases": {
"title": "Pool Aliases",
"description": "Pool Aliases are used to determine which Template Pool can be a substitute.",
"type": "array",
"items": {
"$ref": "./pool_aliases.json"
}
},
"dimension_padding": {
"anyOf": [
{
"title": "Dimension Padding",
"description": "Dimension padding prevents the structure from getting cut off at the top or bottom of the world.",
"type": "integer",
"minimum": 0,
"default": 0
},
{
"title": "Dimension Padding",
"description": "Dimension padding prevents the structure from getting cut off at the top or bottom of the world.",
"type": "object",
"additionalProperties": false,
"properties": {
"top": {
"title": "Top",
"description": "Distance in blocks from the top of the dimension that may not be used by the Jigsaw Structure.",
"type": "integer",
"minimum": 0,
"default": 0
},
"bottom": {
"title": "Bottom",
"description": "Distance in blocks from the bottom of the dimension that may not be used by the Jigsaw Structure.",
"type": "integer",
"minimum": 0,
"default": 0
}
}
}
]
},
"step": {
"title": "Step",
"description": "Specifies the world generation phase in which the structure is generated. This is used as a grouping concept to keep similar world-generation features generally bundled together.",
"type": "string",
"enum": [
"fluid_springs",
"lakes",
"local_modifications",
"raw_generation",
"strongholds",
"surface_structures",
"top_layer_modification",
"underground_decoration",
"underground_ores",
"underground_structures",
"vegetal_decoration"
]
},
"terrain_adaptation": {
"title": "Terrain Adaptation",
"description": "How the terrain should adapt relative to the generated Jigsaw Structure.",
"type": "string",
"enum": [
"beard_box",
"beard_thin",
"bury",
"encapsulate",
"none"
]
},
"liquid_settings": {
"title": "Liquid Settings",
"description": "How to handle waterloggable blocks overlapping with existing liquid.",
"type": "string",
"enum": [ "apply_waterlogging", "ignore_waterlogging" ]
}
}
}
"$id": "blockception.minecraft.behavior.worldgen.jigsaw_structures.minecraft.jigsaw",
"type": "object",
"title": "Jigsaw",
"additionalProperties": false,
"required": ["description", "max_depth", "start_height", "start_pool", "step"],
"properties": {
"biome_filters": {
"title": "Biome Filters",
"description": "Specifies the biomes in which the Jigsaw Structure can generate.",
"$ref": "../../../entities/filters/filters.json"
},
"description": {
"title": "Description",
"description": "The description of this jigsaw.",
"type": "object",
"additionalProperties": false,
"required": ["identifier"],
"properties": {
"identifier": {
"title": "Identifier",
"description": "Identifier of the Jigsaw Structure. This is used with commands such as /locate, as well as within Structure Set definitions to specify which Jigsaw Structures are included in a given set.",
"type": "string"
}
}
},
"heightmap_projection": {
"title": "Heightmap Projection",
"description": "Heightmap used to calculate the relative start height. For example, a heightmap_projection of ocean_floor and a start_height of 10 means the Jigsaw Structure will begin generating 10 blocks above the ocean floor.",
"type": "string",
"enum": ["ocean_floor", "world_surface"]
},
"max_depth": {
"title": "Max Depth",
"type": "integer",
"description": " The maximum recursion depth for Jigsaw Structure Generation. For example, a Jigsaw Structure that builds a road with a max_depth of 5 will only have paths that are a maximum of 5 structures templates in length in any given direction from the origin.",
"minimum": 0.0,
"maximum": 20.0
},
"start_height": {
"title": "Start Height",
"description": "Height at which the Jigsaw Structure's start_pool should begin.",
"$ref": "./height_provider.json"
},
"start_pool": {
"title": "Start Pool",
"type": "string",
"description": "The first Template Pool to use when generating the Jigsaw Structure."
},
"start_jigsaw_name": {
"title": "Start Jigsaw Name",
"description": "The name of the Jigsaw Block from the start_pool to be placed first.",
"type": "string"
},
"max_distance_from_center": {
"title": "Max Distance From Center",
"description": "The max distance from the jigsaw pieces to the structure start.",
"type": "integer",
"minimum": 1,
"maximum": 128
},
"pool_aliases": {
"title": "Pool Aliases",
"description": "Pool Aliases are used to determine which Template Pool can be a substitute.",
"type": "array",
"items": {
"$ref": "./pool_aliases.json"
}
},
"dimension_padding": {
"anyOf": [
{
"title": "Dimension Padding",
"description": "Dimension padding prevents the structure from getting cut off at the top or bottom of the world.",
"type": "integer",
"minimum": 0,
"default": 0
},
{
"title": "Dimension Padding",
"description": "Dimension padding prevents the structure from getting cut off at the top or bottom of the world.",
"type": "object",
"additionalProperties": false,
"properties": {
"top": {
"title": "Top",
"description": "Distance in blocks from the top of the dimension that may not be used by the Jigsaw Structure.",
"type": "integer",
"minimum": 0,
"default": 0
},
"bottom": {
"title": "Bottom",
"description": "Distance in blocks from the bottom of the dimension that may not be used by the Jigsaw Structure.",
"type": "integer",
"minimum": 0,
"default": 0
}
}
}
]
},
"step": {
"title": "Step",
"description": "Specifies the world generation phase in which the structure is generated. This is used as a grouping concept to keep similar world-generation features generally bundled together.",
"type": "string",
"enum": [
"fluid_springs",
"lakes",
"local_modifications",
"raw_generation",
"strongholds",
"surface_structures",
"top_layer_modification",
"underground_decoration",
"underground_ores",
"underground_structures",
"vegetal_decoration"
]
},
"terrain_adaptation": {
"title": "Terrain Adaptation",
"description": "How the terrain should adapt relative to the generated Jigsaw Structure.",
"type": "string",
"enum": ["beard_box", "beard_thin", "bury", "encapsulate", "none"]
},
"liquid_settings": {
"title": "Liquid Settings",
"description": "How to handle waterloggable blocks overlapping with existing liquid.",
"type": "string",
"enum": ["apply_waterlogging", "ignore_waterlogging"]
}
}
}

View File

@@ -1,17 +1,59 @@
{
"title": "Pool Alias",
"description": "Used to rewire jigsaw pool connections by redirecting pool references in an individual structure. Done by specifying aliases for Template Pools. This can allow for themes across a full structure.",
"type": "object",
"properties": {
"$ref": "#/definitions/pool_alias",
"definitions": {
"pool_alias": {
"title": "Pool Alias",
"description": "Used to rewire jigsaw pool connections by redirecting pool references in an individual structure. Done by specifying aliases for Template Pools. This can allow for themes across a full structure.",
"type": "object",
"properties": {
"type": {
"title": "Type",
"type": "string",
"enum": [ "direct", "random", "random_group" ]
"title": "Type",
"type": "string",
"enum": ["direct", "random", "random_group"]
}
},
"allOf": [
},
"allOf": [
{ "if": { "properties": { "processor_type": { "const": "direct" } } }, "then": { "$ref": "./pool_aliases/direct.json" } },
{ "if": { "properties": { "processor_type": { "const": "random" } } }, "then": { "$ref": "./pool_aliases/random.json" } },
{ "if": { "properties": { "processor_type": { "const": "random_group" } } }, "then": { "$ref": "./pool_aliases/random_group.json" } }
]
}
{ "if": { "properties": { "processor_type": { "const": "random_group" } } }, "then": { "$ref": "#/definitions/random_group" } }
]
},
// Inifite loop
"random_group": {
"title": "Random Group",
"type": "object",
"properties": {
"type": {
"title": "Type",
"type": "string",
"const": "random_group"
},
"groups": {
"title": "Groups",
"description": "A weighted random list containing items that contain pool alias items. The pool alias types can be any valid type except random_group.",
"type": "array",
"items": {
"title": "Weighted Random Item",
"description": "A used by Weighted Random Lists.",
"type": "object",
"additionalProperties": false,
"properties": {
"data": {
"title": "Data",
"description": "The data used when randomly selected.",
"$ref": "#/definitions/pool_alias"
},
"weight": {
"title": "Weight",
"description": "The weight of the item relative to the total weight of all items in the list.",
"type": "integer",
"minimum": 1
}
}
}
}
},
"required": ["groups", "type"]
}
}
}

View File

@@ -1,26 +1,22 @@
{
"title": "Direct",
"type": "object",
"properties": {
"type": {
"title": "Type",
"type": "string",
"const": "direct"
},
"alias": {
"title": "Alias",
"description": "The alias of the Template Pool to replace.",
"type": "string"
},
"target": {
"title": "Target",
"description": "The Template Pool to substitute when matched.",
"type": "string"
}
"title": "Direct",
"type": "object",
"properties": {
"type": {
"title": "Type",
"type": "string",
"const": "direct"
},
"required": [
"target",
"alias",
"type"
]
}
"alias": {
"title": "Alias",
"description": "The alias of the Template Pool to replace.",
"type": "string"
},
"target": {
"title": "Target",
"description": "The Template Pool to substitute when matched.",
"type": "string"
}
},
"required": ["target", "alias", "type"]
}

View File

@@ -1,47 +1,43 @@
{
"title": "Random",
"type": "object",
"properties": {
"type": {
"title": "Type",
"type": "string",
"const": "random"
},
"alias": {
"title": "Alias",
"description": "The alias of the Template Pool to replace.",
"type": "string"
},
"targets": {
"title": "Target",
"description": "The Template Pool to substitute when matched.",
"type": "array",
"items": {
"title": "Weighted Random Item",
"description": "A used by Weighted Random Lists.",
"type": "object",
"additionalProperties": false,
"properties": {
"data": {
"title": "Data",
"description": "The data used when randomly selected.",
"type": "string"
},
"weight": {
"title": "Weight",
"description": "The weight of the item relative to the total weight of all items in the list.",
"type": "integer",
"minimum": 1
}
}
},
"minItems": 2,
"maxItems": 2
}
"title": "Random",
"type": "object",
"properties": {
"type": {
"title": "Type",
"type": "string",
"const": "random"
},
"required": [
"targets",
"alias",
"type"
]
}
"alias": {
"title": "Alias",
"description": "The alias of the Template Pool to replace.",
"type": "string"
},
"targets": {
"title": "Target",
"description": "The Template Pool to substitute when matched.",
"type": "array",
"items": {
"title": "Weighted Random Item",
"description": "A used by Weighted Random Lists.",
"type": "object",
"additionalProperties": false,
"properties": {
"data": {
"title": "Data",
"description": "The data used when randomly selected.",
"type": "string"
},
"weight": {
"title": "Weight",
"description": "The weight of the item relative to the total weight of all items in the list.",
"type": "integer",
"minimum": 1
}
}
},
"minItems": 2,
"maxItems": 2
}
},
"required": ["targets", "alias", "type"]
}

View File

@@ -1,39 +0,0 @@
{
"title": "Random Group",
"type": "object",
"properties": {
"type": {
"title": "Type",
"type": "string",
"const": "random_group"
},
"groups": {
"title": "Groups",
"description": "A weighted random list containing items that contain pool alias items. The pool alias types can be any valid type except random_group.",
"type": "array",
"items": {
"title": "Weighted Random Item",
"description": "A used by Weighted Random Lists.",
"type": "object",
"additionalProperties": false,
"properties": {
"data": {
"title": "Data",
"description": "The data used when randomly selected.",
"$ref": "../pool_aliases.json"
},
"weight": {
"title": "Weight",
"description": "The weight of the item relative to the total weight of all items in the list.",
"type": "integer",
"minimum": 1
}
}
}
}
},
"required": [
"groups",
"type"
]
}

View File

@@ -1,13 +1,13 @@
{
"$schema": "http://json-schema.org/draft-07/schema",
"$id": "blockception.minecraft.behavior.worldgen.jigsaw_structures.jigsaw",
"type": "object",
"title": "Jigsaw",
"description": "A Jigsaw Structure is a group of Structure Templates that make up a larger structure. Jigsaw Structures are placed during world generation.",
"required": [ "format_version", "minecraft:jigsaw" ],
"additionalProperties": false,
"properties": {
"format_version": { "$ref": "../../../general/format_version.json" },
"minecraft:jigsaw": { "$ref": "./format/minecraft.jigsaw.json" }
}
}
"$schema": "http://json-schema.org/draft-07/schema",
"$id": "blockception.minecraft.behavior.worldgen.jigsaw_structures.jigsaw",
"type": "object",
"title": "Jigsaw",
"description": "A Jigsaw Structure is a group of Structure Templates that make up a larger structure. Jigsaw Structures are placed during world generation.",
"required": ["format_version", "minecraft:jigsaw"],
"additionalProperties": false,
"properties": {
"format_version": { "$ref": "../../../general/format_version.json" },
"minecraft:jigsaw": { "$ref": "./format/minecraft.jigsaw.json" }
}
}