Everything posted by Erfurt
-
[1.12] Custom Crafting with OreDictionary?
Ahh I see, got confused by the link to another post that used "ingredients", so I thought that it was a forge thing, my bad. So just to be sure it should be like this. { "type": "forge:ore_shaped", "pattern": [ "XX", "X#", " #" ], "key": { "#": { "type": "forge:ore_dict", "ore": "stickWood" }, "X": { "item": "em:amethyst" } }, "result": { "item": "em:amethyst_axe" } }
-
[1.12] Custom Crafting with OreDictionary?
So I have been working on this for a couple of days now, and it doesn't work for me. I'm trying to use both ore dictionary and items in my recipes. as in this example { "type": "forge:ore_shaped", "pattern": [ "XX", "X#", " #" ], "ingredients": [ { "#": { "type": "forge:ore_dict", "ore": "stickWood" }, "X": { "item": "em:amethyst" } } ], "result": { "item": "em:amethyst_axe" } } But it doesn't work. I get this error Is it even possible to use both in the same recipe? (It should be in my opinion)
-
[1.12] Custom Crafting with OreDictionary?
Okay, just tedious to do when you have 50+ blocks, and already have a good system to add crafting, but I guess that once it's done I don't have to think about it until Mojang decides to change crafting again. Oh well thank you
-
[1.12] Custom Crafting with OreDictionary?
Thank you, but does this mean that you can only use OreDictionary by creating the json recipe files yourself, there's not a piece of code that can be used to create them?
-
[1.12] Custom Crafting with OreDictionary?
Hey guys, just a quick little question. Have crafting with OreDictionary been removed? If not, where can I locate the new method for it? Crafting with OreDictionary is/was extremely useful in my opinion, and I would very much like to use it if I can.
-
[1.11.2] Checking block above
Mostly because I was writing this code while half asleep, but my code should and does still work, other than that one if statement. EDIT: Maybe I need there to be an if statement, because I would need to put in some other code, when I had it working.
-
[1.11.2] Checking block above
Might as well show you the whole class I have been testing if the property BLOCK_ABOVE is working, by adding it to one of the other working if statements. Where it does work. So I can conclude that it has something to do with this if statement. if(!(block_above.getMaterial() == Material.AIR)) { state = state.withProperty(BLOCK_ABOVE, true); } else state = state.withProperty(BLOCK_ABOVE, false); I just can't see what's wrong with it, and as I mentioned in an earlier post, I was expecting this to return true when there's a block above and false when it's block using the material air, at least that's my end goal.
-
[1.11.2] Checking block above
What I mean, is that no matter what's above my block, I get the same false result on my BLOCK_ABOVE property. What I expect is when there's any kind of block above it, the property should return true and not false, unless it's an air block/material.
-
[1.11.2] Checking block above
Hey guys, So a quick question. I'm trying to check the block above my custom block to see if it's not an air block/material, I would like it to be compatible with mods that adds gasses and other stuff, that uses Material.Air. But for some reason it doesn't work. This is what I'm trying. @Override public IBlockState getActualState(IBlockState state, IBlockAccess world, BlockPos pos) { IBlockState block_above = world.getBlockState(pos.up()); if(!(block_above.getMaterial() == Material.AIR)) { state = state.withProperty(BLOCK_ABOVE, true); } else state = state.withProperty(BLOCK_ABOVE, false); if(block_above.getProperties().containsValue(BlockSlab.EnumBlockHalf.TOP) || block_above.getProperties().containsValue(BlockStairs.EnumHalf.TOP)) { state = state.withProperty(SLAB_STAIR_ABOVE, true); } else state = state.withProperty(SLAB_STAIR_ABOVE, false); return state; } So the first if statement is the one that doesn't work. The second one works fine. Any idea what I'm doing wrong?
-
[1.11.2] Forge's blockstates with subBlocks
Ahh, got it now
-
[1.11.2] Forge's blockstates with subBlocks
This is the way I have to do to make the items work. { "forge_marker": 1, "defaults": { "particle" : "#all", "model": "em:chimney", "uvlock": true }, "variants": { "slab_stair" : { "true" : { "submodel": "em:chimney_bottom" }, "false" : { } }, "type" : { "stonebrick" : { "textures": { "all": "blocks/stonebrick" } }, "endbrick" : { "textures": { "all": "blocks/end_bricks" } }, "brick" : { "textures": { "all": "blocks/brick" } }, "cobblestone" : { "textures": { "all": "blocks/cobblestone" } }, "sandstone" : { "textures": { "all": "blocks/sandstone_top" } }, "red_sandstone" : { "textures": { "all": "blocks/red_sandstone_top" } } }, "stonebrick" : { "model": "em:chimney", "uvlock": true, "textures": { "all": "blocks/stonebrick" } }, "endbrick" : { "model": "em:chimney", "uvlock": true, "textures": { "all": "blocks/end_bricks" } }, "brick" : { "model": "em:chimney", "uvlock": true, "textures": { "all": "blocks/brick" } }, "cobblestone" : { "model": "em:chimney", "uvlock": true, "textures": { "all": "blocks/cobblestone" } }, "sandstone" : { "model": "em:chimney", "uvlock": true, "textures": { "all": "blocks/sandstone_top" } }, "red_sandstone" : { "model": "em:chimney", "uvlock": true, "textures": { "all": "blocks/red_sandstone_top" } } } } But I would like to know if there's a way to use the "type" part, for the items?
-
[1.11.2] Forge's blockstates with subBlocks
Actually, not everything is working... The items doesn't work. Do I need to make separate json files for them, or is it possible to get them from the blockstate? Don't know if you'll need this, but here's the newest fml-client-latest.log
-
[1.11.2] Forge's blockstates with subBlocks
I feel like an ass... So stupid of me not noticing that... Everything works now, thanks for your help
-
[1.11.2] Forge's blockstates with subBlocks
Maybe it's me who's a complete idiot or something, but I don't get it. I have removed the modelBakery stuff, and also removed the ' "_" + ' from the registerRender. Which is what I get was wrong? Still doesn't work. Does my blockstate look correct to you, I want my types to be named "stonebrick" and not "_stonebrick"? Here's the fml-client-latest.log, there's a lot of stuff in my mod atm, so it's a bit long. EDIT: I haven't changed the json file
-
[1.11.2] Forge's blockstates with subBlocks
Here's all my code. I personally think it's most likely to be the way I register my renders, or the registerModelBakery, that's the problem, but I don't really know.
-
[1.11.2] Forge's blockstates with subBlocks
Hey guys, I was wondering if there's an easy way to use forge's blockstates with subBlocks? Would it work the same as for regular blocks, meaning I don't need to make a .json file for the models.block and the models.item? What I mean is, like the way you can use it with a PropertyBool. Example below. { "forge_marker": 1, "defaults": { "textures": { "all": "#texture" } }, "variants": { "normal" : { "model": "#model", "uvlock": true }, "#bool" : { "true" : { "model": "#model", "uvlock": true, "submodel": "#subModel" }, "false" : { "model": "#model", "uvlock": true }, } } } I'm using a PropertyEnum to add my subBlocks, and I call it type. So in my mind it should be something like this. { "forge_marker": 1, "defaults": { "particle": "#all", "model": "#model", "uvlock": true }, "variants": { "type" : { "#enumName1" : { "textures": { "all": "#texture" } }, "#enumName2" : { "textures": { "all": "#texture" } } } } } Also if I have both in my class, wouldn't it be something like this? { "forge_marker": 1, "defaults": { "particle": "#all" }, "variants": { "type" : { "#enumName1" : { "textures": { "all": "#texture" } }, "#enumName2" : { "textures": { "all": "#texture" } } }, "#bool" : { "true" : { "model": "#model", "uvlock": true, "submodel": "#subModel" }, "false" : { "model": "#model", "uvlock": true }, } } } I should mention that at this times, it's only the texture that seems to not be working.
-
[1.11.2] [Solved] Problems with PathNodeType in custom block class
I'm an idiot... It would seem that when I updated my mod, I somehow fucked up. So that I was still working in the old 1.10.2 version, which makes so much more sense. Sorry for wasting your time, thanks for your help though
-
[1.11.2] [Solved] Problems with PathNodeType in custom block class
I agree, most likely me who doesn't understand that code. But for the method I'm using, I can't seem to find it anywhere, other than on the github page. I see nothing in ref files, which I find a bit weird if it's completely implemented, but maybe I'm looking in the wrong places? Also I'm on the 13.20.0.2282 build, maybe it's not in that one?
-
[1.11.2] [Solved] Problems with PathNodeType in custom block class
It is, but it seems that it's just looping, but not doing anything. Maybe I'm doing something wrong
-
[1.11.2] [Solved] Problems with PathNodeType in custom block class
Nothing seems to be happening. Do I need t o implement something or is there something wrong with the method I use?
-
[1.11.2] [Solved] Problems with PathNodeType in custom block class
You properly want to see my class, so here it is
-
[1.11.2] [Solved] Problems with PathNodeType in custom block class
Not as far as I can tell
-
[1.11.2] [Solved] Problems with PathNodeType in custom block class
Well mobs like Zombies and villagers, try to 'jump' over my hedge, which they shouldn't if the PathNodeType was actually set to FENCE. So that why it doesn't seem to work.
-
[1.11.2] [Solved] Problems with PathNodeType in custom block class
Hey, I'm working on some hedges and would like to use the PathNodeType, to set the PathNodeType of my hedge to fences. But it doesn't seem to work. So I was wondering if it is fully implemented, and working?My hedge class is extending block, so unless the PathNodeType method is in another class, that souldn't be the problem, but maybe I'm using the wrong method to add PathNodeType? Is it still like this, as it is in the github? https://github.com/MinecraftForge/MinecraftForge/pull/3546 @Nullable @Override public PathNodeType getAiPathNodeType(IBlockState state, IBlockAccess world, BlockPos pos) { return PathNodeType.FENCE; } Any help would be great, not sure how many have any information about this, as it's a relative new 'feature' added to forge.
-
[1.10.2] How to add player specific drops and loot table?
I guess that's why alle the 'tutorials' use something like this, to add drops if (event.getEntity() instanceof EntityZombie) { ItemStack[] stack = new ItemStack[]{new ItemStack('item/block')}; for(int i = 0 ; i < stack.length ; i++) { EntityItem drop = new EntityItem(event.getEntity().worldObj, event.getEntity().posX, event.getEntity().posY, event.getEntity().posZ, stack[i]); event.getDrops().add(drop); } }
IPS spam blocked by CleanTalk.