Jump to content
  • Home
  • Files
  • Docs
Topics
  • All Content

  • This Topic
  • This Forum

  • Advanced Search
  • Existing user? Sign In  

    Sign In



    • Not recommended on shared computers


    • Forgot your password?

  • Sign Up
  • All Activity
  • Home
  • Mod Developer Central
  • Modder Support
  • I HATE block states, and just need help.
Currently Supported: 1.16.X (Latest) and 1.15.X (LTS)
Sign in to follow this  
Followers 2
cmchenry

I HATE block states, and just need help.

By cmchenry, July 12, 2018 in Modder Support

  • Reply to this topic
  • Start new topic

Recommended Posts

cmchenry    0

cmchenry

cmchenry    0

  • Tree Puncher
  • cmchenry
  • Members
  • 0
  • 48 posts
Posted July 12, 2018 (edited)

I've googled around and read the forums for approximately 1 hour. I will not research any further. Can I please receive help on why I am getting this error?

 

Called in ClientProxy init

 

registerItemModel(BlockCropPot, 0)
def registerItemModel(block: Block, meta: Int): Unit = {
  val item = Item.getItemFromBlock(block)
  val model = new ModelResourceLocation(getRegistryName.toString, "inventory")
  ModelBakery.registerItemVariants(item, model)
  Minecraft.getMinecraft.getRenderItem.getItemModelMesher.register(item, meta, model)
}

Called in Client Proxy PreInit

OBJLoader.INSTANCE.addDomain(DrugMod.modid)

 

object BlockCropPot extends BlockFarmland {

  setRegistryName(DrugMod.modid, "crop_pot")
  setUnlocalizedName(DrugMod.modid + ":crop_pot")
  setCreativeTab(CreativeTabs.FOOD)

}

 

 

{
  "forge_marker" : 1,
  "defaults" : {
    "textures" : {
      "#material" : "drug:block/crop_pot_dry"
    },
    "model" : "drug:crop_pot.obj",
    "transform": "forge:default-block"
  },
  "variants": {
    "inventory": { "model": "drug:crop_pot.obj" },
    "moisture=0": {
        "textures": {
          "#material":"drug:block/crop_pot_dry"
        }
    },
    "moisture=1": {
      "textures": {
        "#material":"drug:block/crop_pot_dry"
      }
    },
    "moisture=2": {
      "textures": {
        "#material":"drug:block/crop_pot_dry"
      }
    },
    "moisture=3": {
      "textures": {
        "#material":"drug:block/crop_pot_dry"
      }
    },
    "moisture=4": {
      "textures": {
        "#material":"drug:block/crop_pot_dry"
      }
    },
    "moisture=5": {
      "textures": {
        "#material":"drug:block/crop_pot_dry"
      }
    },
    "moisture=6": {
      "textures": {
        "#material":"drug:block/crop_pot_dry"
      }
    },
    "moisture=7": {
      "textures": {
        "#material":"drug:block/crop_pot_wet"
      }
    }
  }
}

 

The .mtl file

 

# Blender MTL File: 'None'
# Material Count: 1

newmtl material
Ns 96.078431
Ka 1.000000 1.000000 1.000000
Kd 0.640000 0.640000 0.640000
Ks 0.500000 0.500000 0.500000
Ke 0.000000 0.000000 0.000000
Ni 1.000000
d 1.000000
illum 2

 

Last but not least, the error log.

 Exception loading model for variant drug:crop_pot#moisture=5 for blockstate "drug:crop_pot[moisture=5]"
net.minecraftforge.client.model.ModelLoaderRegistry$LoaderException: Exception loading model drug:crop_pot#moisture=5 with loader VariantLoader.INSTANCE, skipping
	at net.minecraftforge.client.model.ModelLoaderRegistry.getModel(ModelLoaderRegistry.java:153) ~[ModelLoaderRegistry.class:?]
	at net.minecraftforge.client.model.ModelLoader.registerVariant(ModelLoader.java:237) ~[ModelLoader.class:?]
	at net.minecraft.client.renderer.block.model.ModelBakery.loadBlock(ModelBakery.java:153) ~[ModelBakery.class:?]
	at net.minecraftforge.client.model.ModelLoader.loadBlocks(ModelLoader.java:225) ~[ModelLoader.class:?]
	at net.minecraftforge.client.model.ModelLoader.setupModelRegistry(ModelLoader.java:152) ~[ModelLoader.class:?]
	at net.minecraft.client.renderer.block.model.ModelManager.onResourceManagerReload(ModelManager.java:28) [ModelManager.class:?]
	at net.minecraft.client.resources.SimpleReloadableResourceManager.registerReloadListener(SimpleReloadableResourceManager.java:121) [SimpleReloadableResourceManager.class:?]
	at net.minecraft.client.Minecraft.init(Minecraft.java:559) [Minecraft.class:?]
	at net.minecraft.client.Minecraft.run(Minecraft.java:421) [Minecraft.class:?]
	at net.minecraft.client.main.Main.main(Main.java:118) [Main.class:?]
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_144]
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_144]
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_144]
	at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_144]
	at net.minecraft.launchwrapper.Launch.launch(Launch.java:135) [launchwrapper-1.12.jar:?]
	at net.minecraft.launchwrapper.Launch.main(Launch.java:28) [launchwrapper-1.12.jar:?]
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_144]
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_144]
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_144]
	at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_144]
	at net.minecraftforge.gradle.GradleStartCommon.launch(GradleStartCommon.java:97) [start/:?]
	at GradleStart.main(GradleStart.java:25) [start/:?]
Caused by: net.minecraft.client.renderer.block.model.ModelBlockDefinition$MissingVariantException
	at net.minecraft.client.renderer.block.model.ModelBlockDefinition.getVariant(ModelBlockDefinition.java:83) ~[ModelBlockDefinition.class:?]
	at net.minecraftforge.client.model.ModelLoader$VariantLoader.loadModel(ModelLoader.java:1182) ~[ModelLoader$VariantLoader.class:?]
	at net.minecraftforge.client.model.ModelLoaderRegistry.getModel(ModelLoaderRegistry.java:149) ~[ModelLoaderRegistry.class:?]
	... 21 more
[16:39:25] [main/ERROR]: Exception loading model for variant drug:crop_pot#moisture=6 for blockstate "drug:crop_pot[moisture=6]"
net.minecraftforge.client.model.ModelLoaderRegistry$LoaderException: Exception loading model drug:crop_pot#moisture=6 with loader VariantLoader.INSTANCE, skipping
	at net.minecraftforge.client.model.ModelLoaderRegistry.getModel(ModelLoaderRegistry.java:153) ~[ModelLoaderRegistry.class:?]
	at net.minecraftforge.client.model.ModelLoader.registerVariant(ModelLoader.java:237) ~[ModelLoader.class:?]
	at net.minecraft.client.renderer.block.model.ModelBakery.loadBlock(ModelBakery.java:153) ~[ModelBakery.class:?]
	at net.minecraftforge.client.model.ModelLoader.loadBlocks(ModelLoader.java:225) ~[ModelLoader.class:?]
	at net.minecraftforge.client.model.ModelLoader.setupModelRegistry(ModelLoader.java:152) ~[ModelLoader.class:?]
	at net.minecraft.client.renderer.block.model.ModelManager.onResourceManagerReload(ModelManager.java:28) [ModelManager.class:?]
	at net.minecraft.client.resources.SimpleReloadableResourceManager.registerReloadListener(SimpleReloadableResourceManager.java:121) [SimpleReloadableResourceManager.class:?]
	at net.minecraft.client.Minecraft.init(Minecraft.java:559) [Minecraft.class:?]
	at net.minecraft.client.Minecraft.run(Minecraft.java:421) [Minecraft.class:?]
	at net.minecraft.client.main.Main.main(Main.java:118) [Main.class:?]
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_144]
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_144]
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_144]
	at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_144]
	at net.minecraft.launchwrapper.Launch.launch(Launch.java:135) [launchwrapper-1.12.jar:?]
	at net.minecraft.launchwrapper.Launch.main(Launch.java:28) [launchwrapper-1.12.jar:?]
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_144]
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_144]
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_144]
	at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_144]
	at net.minecraftforge.gradle.GradleStartCommon.launch(GradleStartCommon.java:97) [start/:?]
	at GradleStart.main(GradleStart.java:25) [start/:?]
Caused by: net.minecraft.client.renderer.block.model.ModelBlockDefinition$MissingVariantException
	at net.minecraft.client.renderer.block.model.ModelBlockDefinition.getVariant(ModelBlockDefinition.java:83) ~[ModelBlockDefinition.class:?]
	at net.minecraftforge.client.model.ModelLoader$VariantLoader.loadModel(ModelLoader.java:1182) ~[ModelLoader$VariantLoader.class:?]
	at net.minecraftforge.client.model.ModelLoaderRegistry.getModel(ModelLoaderRegistry.java:149) ~[ModelLoaderRegistry.class:?]
	... 21 more
[16:39:25] [main/ERROR]: Exception loading model for variant drug:crop_pot#moisture=3 for blockstate "drug:crop_pot[moisture=3]"
net.minecraftforge.client.model.ModelLoaderRegistry$LoaderException: Exception loading model drug:crop_pot#moisture=3 with loader VariantLoader.INSTANCE, skipping
	at net.minecraftforge.client.model.ModelLoaderRegistry.getModel(ModelLoaderRegistry.java:153) ~[ModelLoaderRegistry.class:?]
	at net.minecraftforge.client.model.ModelLoader.registerVariant(ModelLoader.java:237) ~[ModelLoader.class:?]
	at net.minecraft.client.renderer.block.model.ModelBakery.loadBlock(ModelBakery.java:153) ~[ModelBakery.class:?]
	at net.minecraftforge.client.model.ModelLoader.loadBlocks(ModelLoader.java:225) ~[ModelLoader.class:?]
	at net.minecraftforge.client.model.ModelLoader.setupModelRegistry(ModelLoader.java:152) ~[ModelLoader.class:?]
	at net.minecraft.client.renderer.block.model.ModelManager.onResourceManagerReload(ModelManager.java:28) [ModelManager.class:?]
	at net.minecraft.client.resources.SimpleReloadableResourceManager.registerReloadListener(SimpleReloadableResourceManager.java:121) [SimpleReloadableResourceManager.class:?]
	at net.minecraft.client.Minecraft.init(Minecraft.java:559) [Minecraft.class:?]
	at net.minecraft.client.Minecraft.run(Minecraft.java:421) [Minecraft.class:?]
	at net.minecraft.client.main.Main.main(Main.java:118) [Main.class:?]
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_144]
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_144]
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_144]
	at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_144]
	at net.minecraft.launchwrapper.Launch.launch(Launch.java:135) [launchwrapper-1.12.jar:?]
	at net.minecraft.launchwrapper.Launch.main(Launch.java:28) [launchwrapper-1.12.jar:?]
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_144]
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_144]
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_144]
	at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_144]
	at net.minecraftforge.gradle.GradleStartCommon.launch(GradleStartCommon.java:97) [start/:?]
	at GradleStart.main(GradleStart.java:25) [start/:?]
Caused by: net.minecraft.client.renderer.block.model.ModelBlockDefinition$MissingVariantException
	at net.minecraft.client.renderer.block.model.ModelBlockDefinition.getVariant(ModelBlockDefinition.java:83) ~[ModelBlockDefinition.class:?]
	at net.minecraftforge.client.model.ModelLoader$VariantLoader.loadModel(ModelLoader.java:1182) ~[ModelLoader$VariantLoader.class:?]
	at net.minecraftforge.client.model.ModelLoaderRegistry.getModel(ModelLoaderRegistry.java:149) ~[ModelLoaderRegistry.class:?]
	... 21 more
[16:39:25] [main/ERROR]: Exception loading model for variant drug:crop_pot#moisture=4 for blockstate "drug:crop_pot[moisture=4]"
net.minecraftforge.client.model.ModelLoaderRegistry$LoaderException: Exception loading model drug:crop_pot#moisture=4 with loader VariantLoader.INSTANCE, skipping
	at net.minecraftforge.client.model.ModelLoaderRegistry.getModel(ModelLoaderRegistry.java:153) ~[ModelLoaderRegistry.class:?]
	at net.minecraftforge.client.model.ModelLoader.registerVariant(ModelLoader.java:237) ~[ModelLoader.class:?]
	at net.minecraft.client.renderer.block.model.ModelBakery.loadBlock(ModelBakery.java:153) ~[ModelBakery.class:?]
	at net.minecraftforge.client.model.ModelLoader.loadBlocks(ModelLoader.java:225) ~[ModelLoader.class:?]
	at net.minecraftforge.client.model.ModelLoader.setupModelRegistry(ModelLoader.java:152) ~[ModelLoader.class:?]
	at net.minecraft.client.renderer.block.model.ModelManager.onResourceManagerReload(ModelManager.java:28) [ModelManager.class:?]
	at net.minecraft.client.resources.SimpleReloadableResourceManager.registerReloadListener(SimpleReloadableResourceManager.java:121) [SimpleReloadableResourceManager.class:?]
	at net.minecraft.client.Minecraft.init(Minecraft.java:559) [Minecraft.class:?]
	at net.minecraft.client.Minecraft.run(Minecraft.java:421) [Minecraft.class:?]
	at net.minecraft.client.main.Main.main(Main.java:118) [Main.class:?]
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_144]
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_144]
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_144]
	at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_144]
	at net.minecraft.launchwrapper.Launch.launch(Launch.java:135) [launchwrapper-1.12.jar:?]
	at net.minecraft.launchwrapper.Launch.main(Launch.java:28) [launchwrapper-1.12.jar:?]
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_144]
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_144]
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_144]
	at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_144]
	at net.minecraftforge.gradle.GradleStartCommon.launch(GradleStartCommon.java:97) [start/:?]
	at GradleStart.main(GradleStart.java:25) [start/:?]
Caused by: net.minecraft.client.renderer.block.model.ModelBlockDefinition$MissingVariantException
	at net.minecraft.client.renderer.block.model.ModelBlockDefinition.getVariant(ModelBlockDefinition.java:83) ~[ModelBlockDefinition.class:?]
	at net.minecraftforge.client.model.ModelLoader$VariantLoader.loadModel(ModelLoader.java:1182) ~[ModelLoader$VariantLoader.class:?]
	at net.minecraftforge.client.model.ModelLoaderRegistry.getModel(ModelLoaderRegistry.java:149) ~[ModelLoaderRegistry.class:?]
	... 21 more

 

Edited July 12, 2018 by cmchenry
Add error log. *derp*
  • Quote

Share this post


Link to post
Share on other sites

larsgerrits    514

larsgerrits

larsgerrits    514

  • Reality Controller
  • larsgerrits
  • Members
  • 514
  • 3462 posts
Posted July 12, 2018

https://mcforge.readthedocs.io/en/latest/models/blockstates/forgeBlockstates/

Have you read this?

  • Quote

Don't PM me with questions. They will be ignored! Make a thread on the appropriate board for support.

 

1.12 -> 1.13 primer by williewillus.

 

1.7.10 and older versions of Minecraft are no longer supported due to it's age! Update to the latest version for support.

 

http://www.howoldisminecraft1710.today/

Share this post


Link to post
Share on other sites

cmchenry    0

cmchenry

cmchenry    0

  • Tree Puncher
  • cmchenry
  • Members
  • 0
  • 48 posts
Posted July 12, 2018
Just now, larsgerrits said:

https://mcforge.readthedocs.io/en/latest/models/blockstates/forgeBlockstates/

Have you read this?

I have not. I will read it and get back to you on my results. ?

  • Quote

Share this post


Link to post
Share on other sites

cmchenry    0

cmchenry

cmchenry    0

  • Tree Puncher
  • cmchenry
  • Members
  • 0
  • 48 posts
Posted July 12, 2018 (edited)

In Client Proxy PreInit

 

ModelLoader.setCustomModelResourceLocation(Item.getItemFromBlock(BlockCropPot), 0, new ModelResourceLocation(BlockCropPot.getRegistryName, "inventory"))

 

The JSON

{
  "forge_marker" : 1,
  "defaults" : {
    "textures" : {
      "#material" : "drug:block/crop_pot_dry"
    },
    "model" : "drug:crop_pot.obj",
    "transform": "forge:default-block"
  },
  "variants": {
    "normal": [{
      "model": "drug:block/crop_pot",
      "textures": {
        "#material":"drug:block/crop_pot_dry"
      }
    }],
    "inventory": [{
      "model": "drug:block/crop_pot",
      "textures": {
        "#material":"drug:block/crop_pot_dry"
      }
    }],
    "moisture": {
      "0": { "textures": { "#material":"drug:block/crop_pot_dry" } },
      "1": { "textures": { "#material":"drug:block/crop_pot_dry" } },
      "2": { "textures": { "#material":"drug:block/crop_pot_dry" } },
      "3": { "textures": { "#material":"drug:block/crop_pot_dry" } },
      "4": { "textures": { "#material":"drug:block/crop_pot_dry" } },
      "5": { "textures": { "#material":"drug:block/crop_pot_dry" } },
      "6": { "textures": { "#material":"drug:block/crop_pot_dry" } },
      "7": { "textures": { "#material":"drug:block/crop_pot_wet" } }
    }
  }
}

 

This contains no errors. Only problem now is that the block is a purple/black block (ya know, the one that's missing its model) and the model has no texture. Also how do I disable culling? It seems to be culling the OBJ=NOT GOOD.

 

Edited July 12, 2018 by cmchenry
  • Quote

Share this post


Link to post
Share on other sites

larsgerrits    514

larsgerrits

larsgerrits    514

  • Reality Controller
  • larsgerrits
  • Members
  • 514
  • 3462 posts
Posted July 12, 2018 (edited)

1) Don't add '#' in front of texture definitions, only when referencing them for models.

2) Did you register your mod to the OBJLoader? I'm blind.

Edited July 12, 2018 by larsgerrits
  • Quote

Don't PM me with questions. They will be ignored! Make a thread on the appropriate board for support.

 

1.12 -> 1.13 primer by williewillus.

 

1.7.10 and older versions of Minecraft are no longer supported due to it's age! Update to the latest version for support.

 

http://www.howoldisminecraft1710.today/

Share this post


Link to post
Share on other sites

cmchenry    0

cmchenry

cmchenry    0

  • Tree Puncher
  • cmchenry
  • Members
  • 0
  • 48 posts
Posted July 12, 2018
{
  "forge_marker" : 1,
  "defaults" : {
    "textures" : {
      "material" : "drug:block/crop_pot_dry"
    },
    "model" : "drug:crop_pot.obj",
    "transform": "forge:default-block"
  },
  "variants": {
    "normal": [{
      "model": "drug:block/crop_pot",
      "textures": {
        "material":"drug:block/crop_pot_dry"
      }
    }],
    "inventory": [{
      "model": "drug:block/crop_pot",
      "textures": {
        "material":"drug:block/crop_pot_dry"
      }
    }],
    "moisture": {
      "0": { "textures": { "material":"drug:block/crop_pot_dry" } },
      "1": { "textures": { "material":"drug:block/crop_pot_dry" } },
      "2": { "textures": { "material":"drug:block/crop_pot_dry" } },
      "3": { "textures": { "material":"drug:block/crop_pot_dry" } },
      "4": { "textures": { "material":"drug:block/crop_pot_dry" } },
      "5": { "textures": { "material":"drug:block/crop_pot_dry" } },
      "6": { "textures": { "material":"drug:block/crop_pot_dry" } },
      "7": { "textures": { "material":"drug:block/crop_pot_wet" } }
    }
  }
}

 

Textures still don't work.

  • Quote

Share this post


Link to post
Share on other sites

cmchenry    0

cmchenry

cmchenry    0

  • Tree Puncher
  • cmchenry
  • Members
  • 0
  • 48 posts
Posted July 12, 2018 (edited)

Okay I got the textures to load, but for some reason it doesn't show properly in MC on the model. Is it because I triangulated the faces?

 

{
  "forge_marker" : 1,
  "defaults" : {
    "textures" : {
      "#material" : "drug:block/crop_pot_dry"
    },
    "model" : "drug:crop_pot.obj",
    "transform": "forge:default-block"
  },
  "variants": {
    "normal": [{
      "model": "drug:block/crop_pot"
    }],
    "inventory": [{
      "model": "drug:block/crop_pot"
    }],
    "moisture": {
      "0": { "textures": { "#material":"drug:block/crop_pot_dry" } },
      "1": { "textures": { "#material":"drug:block/crop_pot_dry" } },
      "2": { "textures": { "#material":"drug:block/crop_pot_dry" } },
      "3": { "textures": { "#material":"drug:block/crop_pot_dry" } },
      "4": { "textures": { "#material":"drug:block/crop_pot_dry" } },
      "5": { "textures": { "#material":"drug:block/crop_pot_dry" } },
      "6": { "textures": { "#material":"drug:block/crop_pot_dry" } },
      "7": { "textures": { "#material":"drug:block/crop_pot_wet" } }
    }
  }
}
Edited July 12, 2018 by cmchenry
  • Quote

Share this post


Link to post
Share on other sites

cmchenry    0

cmchenry

cmchenry    0

  • Tree Puncher
  • cmchenry
  • Members
  • 0
  • 48 posts
Posted July 12, 2018

The image size in 128x128. Is that not valid? 

Capture2.PNG

Capture1.PNG

  • Quote

Share this post


Link to post
Share on other sites

cmchenry    0

cmchenry

cmchenry    0

  • Tree Puncher
  • cmchenry
  • Members
  • 0
  • 48 posts
Posted July 12, 2018

To fix the issue I was having follow this video: 

 

 

 

Capture12.PNG

  • Quote

Share this post


Link to post
Share on other sites

cmchenry    0

cmchenry

cmchenry    0

  • Tree Puncher
  • cmchenry
  • Members
  • 0
  • 48 posts
Posted July 12, 2018

So to fully fix all clipping in my block class I had to add 

 

override def shouldSideBeRendered(blockState: IBlockState, blockAccess: IBlockAccess, pos: BlockPos, side: EnumFacing): Boolean = true

override def isOpaqueCube(state: IBlockState): Boolean = false

override def isFullCube(state: IBlockState): Boolean = false

 

And then in blender I had to of course fix the normals like in the video above, and then I had to render without Triangulating Faces, but sometimes that may fix it.

 

Final JSON

{
  "forge_marker" : 1,
  "defaults" : {
    "textures" : {
      "#material" : "drug:block/crop_pot_dry"
    },
    "custom": { "flip-v": true },
    "model" : "drug:crop_pot.obj",
    "transform": "forge:default-item"
  },
  "variants": {
    "normal": [{
      "model": "drug:block/crop_pot"
    }],
    "inventory": [{
      "model": "drug:block/crop_pot"
    }],
    "moisture": {
      "0": { "textures": { "#material":"drug:block/crop_pot_dry" } },
      "1": { "textures": { "#material":"drug:block/crop_pot_dry" } },
      "2": { "textures": { "#material":"drug:block/crop_pot_dry" } },
      "3": { "textures": { "#material":"drug:block/crop_pot_dry" } },
      "4": { "textures": { "#material":"drug:block/crop_pot_dry" } },
      "5": { "textures": { "#material":"drug:block/crop_pot_dry" } },
      "6": { "textures": { "#material":"drug:block/crop_pot_dry" } },
      "7": { "textures": { "#material":"drug:block/crop_pot_wet" } }
    }
  }
}
  • Quote

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

    • Insert image from URL
×
  • Desktop
  • Tablet
  • Phone
Sign in to follow this  
Followers 2
Go To Topic Listing



  • Recently Browsing

    No registered users viewing this page.

  • Posts

    • cadbane86140
      Minecraft: Hunger Games Game #36- Shear FIGHT!

      By cadbane86140 · Posted 30 minutes ago

      Hello There! Today we are back on Hunger Games after a little break but we are finally back! In this episode we are on the good ol' map Survival Games 4 and it ACTUALLY went well for once. Also we have so many great battles on rooftops, small rooms and just out in the open! We also use shears to fight at one point and that was pretty crazy! There are so many hilarious moments in this episode that I know you guys are gonna love! I hope you all enjoy this video and if you did don't forget to like and sub for more Hunger Games in the future!  
    • Sad Whale
      Game crashes whenever I try to increase the RAM

      By Sad Whale · Posted 42 minutes ago

      latest.log
    • diesieben07
      Game crashes whenever I try to increase the RAM

      By diesieben07 · Posted 1 hour ago

      In the logs folder of your game directory.
    • Unusualty
      GUI'S and player editing

      By Unusualty · Posted 1 hour ago

      So I'm trying to make a mod that is inspired by Origin's because this mod isn't for forge I was wondering if anyone can help me do something like this where you get a GUI when you join the world where you can select a race that has abilities and down sides to them, I also want to have classes but first I want these race's done so if anyone can help this would be appreciated.
    • Sad Whale
      Game crashes whenever I try to increase the RAM

      By Sad Whale · Posted 1 hour ago

      Would you mind explaining where I can find the debug.log
  • Topics

    • cadbane86140
      0
      Minecraft: Hunger Games Game #36- Shear FIGHT!

      By cadbane86140
      Started 30 minutes ago

    • Sad Whale
      6
      Game crashes whenever I try to increase the RAM

      By Sad Whale
      Started 2 hours ago

    • Unusualty
      0
      GUI'S and player editing

      By Unusualty
      Started 1 hour ago

    • fluiX
      1
      server wont start

      By fluiX
      Started 2 hours ago

    • Luis_ST
      6
      [1.16.5] Help with custom Event

      By Luis_ST
      Started 6 hours ago

  • Who's Online (See full list)

    • NullDev
    • redlynx
    • Microcellule
    • Ch1m3r4
    • ChampionAsh5357
    • ModMCdl
    • Skyriis
    • neobadwolf
    • forgnog
    • mactho
    • vemerion
  • All Activity
  • Home
  • Mod Developer Central
  • Modder Support
  • I HATE block states, and just need help.
  • Theme

Copyright © 2019 ForgeDevelopment LLC · Ads by Longitude Ads LLC Powered by Invision Community