Posted February 7, 20187 yr Hello guys this Json file I made is giving me crashes, { "variants": { "variant=frozen_dirt_grassy": { "snowy=false": { "model": "mtaxspeo:block_frozen_dirt_grassy" }, "snowy=true": { "model": "mtaxspeo:fixme_grass_snowed" } }, "variant=dia_dim_dirt": { "model": "mtaxspeo:fixme_dirt" } } } Can't I have multiple variants with snowy condition? Or am I writing it wrong? Thanks in Advance!
February 7, 20187 yr That is not the proper variant syntax. http://mcforge.readthedocs.io/en/latest/blockstates/forgeBlockstates/ Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable. If you think this is the case, JUST REPORT ME. Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice. Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked. DO NOT PM ME WITH PROBLEMS. No help will be given.
February 7, 20187 yr 24 minutes ago, Draco18s said: That is not the proper variant syntax. http://mcforge.readthedocs.io/en/latest/blockstates/forgeBlockstates/ I didn't know Forge had a special Json syntax. Anyway I didn't understand how am I supposed to write the json file for 2 blocks like I was trying to do. The examples you gave me are "single-block" examples. In my case i got the "frozen_dirt_grassy" block and the "dia_dim_dirt" block, the first has the snow condition and the second is a common dirt block. I know that I could do something like this without the snow condition tho: { "variants": { "variant=frozen_dirt_grassy": { "model": "mtaxspeo:block_frozen_dirt_grassy" }, "variant=dia_dim_dirt": { "model": "mtaxspeo:fixme_dirt" } } } But I still didn't get it where should I add it. Thanks
February 7, 20187 yr When it comes to block states, if one variant has an extra value all others do as well. So you technically have a "variant=dia_dim_dirt,snowy=true" and "variant=dia_dim_dirt,snowy=false" You just don't do anything with them. But your JSON model still needs to specify them. I do Forge for free, however the servers to run it arn't free, so anything is appreciated. Consider supporting the team on Patreon
February 7, 20187 yr 4 minutes ago, LexManos said: When it comes to block states, if one variant has an extra value all others do as well. So you technically have a "variant=dia_dim_dirt,snowy=true" and "variant=dia_dim_dirt,snowy=false" You just don't do anything with them. But your JSON model still needs to specify them. { "variants": { "variant=frozen_dirt_grassy": { "snowy=false": { "model": "mtaxspeo:block_frozen_dirt_grassy" }, "snowy=true": { "model": "mtaxspeo:fixme_grass_snowed" } }, "variant=dia_dim_dirt": { "snowy=false": { "model": "mtaxspeo:fixme_dirt" }, "snowy=true": { "model": "mtaxspeo:fixme_dirt" } } } } Thanks for your answer, shouldn't this work then? Sorry for the newbie questions and thanks
February 7, 20187 yr No you're hybridizing the Forge and Mojang JSON formats. In the mojang version you have to specify all full variants. The point of Forge's json is to build the permutations for you. So you can't nest them like that, you'd need: { "variants": { "variant": { "frozen_dirt_grassy": {}, "dia_dim_dirt": {} }, "snowy": { "true": {}, "false": {} } } } If you have a '=' ANYWHERE in your variant name it detects it as a normal Mojang variant and doesn't build the permutations for you. So ya... read the docs, and either use the Forge version, or Mojang's version. Don't mix the two. I do Forge for free, however the servers to run it arn't free, so anything is appreciated. Consider supporting the team on Patreon
February 7, 20187 yr 16 minutes ago, LexManos said: No you're hybridizing the Forge and Mojang JSON formats. In the mojang version you have to specify all full variants. The point of Forge's json is to build the permutations for you. So you can't nest them like that, you'd need: { "variants": { "variant": { "frozen_dirt_grassy": {}, "dia_dim_dirt": {} }, "snowy": { "true": {}, "false": {} } } } If you have a '=' ANYWHERE in your variant name it detects it as a normal Mojang variant and doesn't build the permutations for you. So ya... read the docs, and either use the Forge version, or Mojang's version. Don't mix the two. Now I understand, Thank you for your help
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.