Perspective awareness for vanilla and multi models, fixes #2148.

Improved error handling in MultiModel.
This commit is contained in:
RainWarrior committed 2015-10-27 17:40:05 +03:00
1 parent cf568ae85f
commit 7c7547227c
11 files changed
+211 -86

No files matched your search

@@ -3,7 +3,8 @@
"defaults": {
"textures": {"wall": "blocks/cobblestone"},
"model": "cobblestone_wall_post",
"uvlock": true // This and all other properties of "defaults" will be inherited by simple submodels. They will NOT be inherited by named submodels.
"uvlock": true, // This and all other properties of "defaults" will be inherited by simple submodels. They will NOT be inherited by named submodels.
"transform": "forge:default-block"
},
"variants": {
"north": {
@@ -24,6 +25,12 @@
},
"up": {"true": {}, "false": {}}, // Must have this in here or the blockstates loader will not know of all the properties and values, and it will create the wrong vanilla state strings.
"east=false,north=true,south=true,up=false,west=false": {"model": null}, // Fully specified variant, will inherit from variants above, but remove the model set in "defaults", removing the wall post.
"east=true,north=false,south=false,up=false,west=true": {"model": null}
"east=true,north=false,south=false,up=false,west=true": {"model": null},
"inventory": [{ // inventory variant can be specified here too, and it will inherit properties from "defaults"
submodel: {
"north": { "model": "forgeblockstatesloader:wall_connect" },
"south": { "model": "forgeblockstatesloader:wall_connect", "y": 180 }
}
}]
}
}
@@ -3,7 +3,8 @@
"defaults": {
"textures": {"wall": "blocks/cobblestone_mossy"},
"model": "cobblestone_wall_post",
"uvlock": true
"uvlock": true,
"transform": "forge:default-block"
},
"variants": {
"north": {
@@ -24,6 +25,12 @@
},
"up": {"true": {}, "false": {}},
"east=false,north=true,south=true,up=false,west=false": {"model": null},
"east=true,north=false,south=false,up=false,west=true": {"model": null}
"east=true,north=false,south=false,up=false,west=true": {"model": null},
"inventory": [{ // inventory variant can be specified here too, and it will inherit properties from "defaults"
submodel: {
"north": { "model": "forgeblockstatesloader:wall_connect" },
"south": { "model": "forgeblockstatesloader:wall_connect", "y": 180 }
}
}]
}
}
@@ -1,6 +0,0 @@
{
"parent": "block/wall_inventory",
"textures": {
"wall": "blocks/cobblestone"
}
}
@@ -1,6 +0,0 @@
{
"parent": "block/wall_inventory",
"textures": {
"wall": "blocks/cobblestone_mossy"
}
}
@@ -2,34 +2,24 @@
"forge_marker": 1,
"defaults": {
"textures": {
"#texture": "forgedebugmodelloaderregistry:texture",
//"#texture": "forgedebugmodelloaderregistry:texture",
"#chest": "entity/chest/normal"
},
"model": "forgedebugmodelloaderregistry:chest.b3d"
"model": "forgedebugmodelloaderregistry:chest.b3d",
"transform": "forge:default-block"
},
"variants": {
"normal": [{
/*"transform": {
"rotation": {"y": 45}
}*/
}],
"normal": [{}],
"inventory": [{
/*"transform": {
"thirdperson": {
"translation": [ 0, 0.09375, -0.171875 ],
"rotation": [ {"y": -45}, {"x": 10}, {"z": 170} ],
"scale": 0.375
}
}*/
"transform": "forge:default-block"
"y": 180
}],
"facing": {
"down": {"model": "forgedebugmodelloaderregistry:chest.b3d", "x": 90},
"up": {"model": "forgedebugmodelloaderregistry:chest.b3d", "x": 270},
"north": {"model": "forgedebugmodelloaderregistry:chest.b3d"},
"south": {"model": "forgedebugmodelloaderregistry:chest.b3d", "y": 180},
"west": {"model": "forgedebugmodelloaderregistry:chest.b3d", "y": 270},
"east": {"model": "forgedebugmodelloaderregistry:chest.b3d", "y": 90}
"down": {"x": 90},
"up": {"x": 270},
"north": {"y": 180},
"south": {},
"west": {"y": 90},
"east": {"y": 270}
}
}
}