Jump to content

trollworkout

Members
  • Posts

    300
  • Joined

Everything posted by trollworkout

  1. The block layer translucent works 100% but the problem is I think it confuses the game because I only have one element that is translucent the rest of the object is solid. I guess there is no way to define only parts of the model as being translucent.
  2. Thanks for your help guys. Is getting better. I had no particle texture set so I think that was the issue. Let's see if it works now. Also I figured out I don't need to define faces that are hidden. I erased all faces that will never be seen. Seems to reduce the issue with transparent water + tinting a bit. Tinting has some weird ass issues sometimes MC can't decide if water is in front or behind of the objects is tinting (or not tinting). Sometimes water would render on top of your blocks or items even the ones held in hand. Haha So random. But overall is wayyy better.
  3. I made some progress. Now my water renders properly and animates like still water. The spout now renders as well. When I break the block, however, is still showing transparent texture bits. And I can see some weird glitches some transparent sides from elements are showing through the block. I need to make them completely invisible.
  4. http://picpaste.com/pics/Screen_Shot_2016-10-18_at_7.06.01_PM-aiK53Npp.1476832329.png[/img] How to make the water in the vat transparent? Also this json is not working for the SPOUT model Yes is like the Witchery Silver Vat. Is intentionally done that way I'm making a mod that borrows ideas and mechanics from older and abandoned mods that will never see 1.10 or over. My mod is completely different tho. I'm not cloning older mods.
  5. Shows up in creative tab public static final Block DEPOSITS_VAT = new DepositsVat().setUnlocalizedName("depositsVat").setRegistryName("depositsVat").setCreativeTab(ModData.CREATIVE_TAB); Doesn't public static final Block DEPOSITS_VAT = new DepositsVat().setUnlocalizedName("depositsVat").setRegistryName("depositsVat"); This doesn't matter public static final ItemBlock DEPOSITS_VAT = (ItemBlock) new ItemBlock(ModBlocks.DEPOSITS_VAT).setUnlocalizedName("depositsVat").setRegistryName("depositsVat").setCreativeTab(ModData.CREATIVE_TAB);
  6. Even if you give it's items a creative tab it will still not show up. Seems the BlockItem's creative tab setting is ingored and the Block will appear only if you set it on the Block side
  7. Item myItem = new Item().setUnlocalizedName("myItem22").setRegistryName("myItem").setCreativeTab(Mod.MY_TAB) in lang file located at src/main/resources/assets/yourmodid/lang/en_US.lang language.name=English language.region=US language.code=en_US item.myItem22.name=My First Item generally for all items is item.UNLOCALIZED NAME.name you can also use minecraft colors like §4 or stuff like that and will show up colored in the game
  8. I found out that deprecated does not mean do not use. Deprecated rather means more like "i'd rather you not use it but if you have to go then go ahead." In my code I have a block which has multi textures and FACING so orientation matters. One of the functions there getStateFromMeta(int meta) is marked as deprecated. @Deprecated public IBlockState getStateFromMeta(int meta) { return this.getDefaultState(); } Now if you don't use this function the block resets position every time you reload the game so in this case is deprecated but YOU HAVE TO USE IT. So what do I do? I use it. There's no other way Point is if it says deprecated is because original MC team are trying to move away from this function so expect it to go away in the future but doesn't mean you can't use it now.
  9. I put mine in init() Why? Because in preInit() is where I register and declare my items and blocks. It kinda helps my brain figure this out. If you're looking for say certain item or block in an event handler and is not registered or defined yet then you get a crash null pointer because items or blocks you were looking for don't exist yet. But I guess you can put it at the end of preInit() ?
  10. I created a custom crop last night. In fact two. And both working fine! You don't need to create a custom seed item. You need, however, to create a custom crop block because getSeed and getCrop needs to be overriden. For seed you can use MC's own ItemSeed or even ItemSeedFood both will work. In my ModItems I got this after which I register in preInit Note that I used MC's own ItemSeedFood . This is fine because it has the crop, seed in the constructor. Minecraft's or is it Forge's own BlockCrop does not have a way to change crop and seed so you need to create a custom one so you can override the return stuff. Note that in ModBlocks I have to register the crop. And finally I have a ModelsHandler class where I register the models for item and for the crop block. I can show you that too. You HAVE to to id properly or else it will not show up. YOu need various models for each crop stage from 0 to 7 . You need a blockstate with age=0 ... age=7 pointing at the above block model. And for the item you just do it the regular way like any other non specific MC item.
  11. Thanks for your suggestions I will try the custom IRecipe object . I wonder how ModTweaker does it.
  12. I mean while game is running. My mod has various techs which start as disabled and get discovered so the user may now build things that previously was not possible. How do I remove vanilla recipes? How do I remove/add new recipes while game is running?
  13. Here is what my BaseBlock class looks like public class BaseBlock extends Block { public BaseBlock(String name, Material materialIn, MapColor mapcolorIn) { super(materialIn, mapcolorIn); this.setUnlocalizedName(name); this.setRegistryName(name); this.setCreativeTab(ModData.CREATIVE_TAB); } } I don't know what the user above is saying but my unlocalized name has never randomly changed EVER. This makes it easy because I know my unlocalized name in lang is same as png file name and same as registry name for the block. steamBoiler.png steamBoiler (block) tile.steamBoiler.name=SteamBoiler life is easy
  14. That's complete BS. Unlocalized name does not change only your lang file changes Registry name is the name of your block/item A block called "BIG_BLOCK" with the unlocalizedName "bigBlock" and registry name "bigBlock" in lang file you can translate in various language say French tile.bigBlock.name=Bloque Grande how did the unlocalized name change? What can make unlocalized name change? Not sure where you got that information that unlocalizedName can change any time but is incorrect. At least no longer in 1.10.2+ .As far as i know you can have multiple unlocalized names based on meta/blockstate for one block/item but they will ALWAYS stay the same unless you change them manually in code. Unlocalized name can always change if YOU change it.
  15. I was thinking of uv texture mapping . When you add a texture to a 3d model and you kinda pick and choose where it goes. All objs used with MC need to have proper uv mapping done. Then when you place a texture on them they will texture themselves the same way you picked. If you never done the uv map is likely the object will look black. Maybe
  16. setRegistryName(unlocalizedName) without this it won't know what the item is cause Forge doesn't use numbers for block/item ids anymore but instead uses the registry name. also models get loaded in @Sided(Side.Client) only while the rest of the code is loaded in common In my mod I separated model loading which is in ModelHandler for items and blocks from blocks ModBlocks and items ModItems and recipes ModRecipes. Also EVERY block needs to have: 1. a blockstate 2. item block + item block model that has parent your mod block 3. block model .
  17. All the above + make sure you got the model json for items and blocks properly. For 1.10.2 is like this. I'm sure 1.8.9 would be similar. In preInit the item is registered as setUnlocalizedName("ingotCopper").setRegistryName("ingotCopper") ModelLoader.setCustomModelResourceLocation(ModItem.INGOT_COPPER, 0, new ModelResourceLocation(ModItem.INGOT_COPPER.getRegistryName(), "inventory")); my json { "parent": "item/generated", "textures": { "layer0": "modid:items/ingotCopper" } } And texture is under src/main/resources/assets/modid/textures/items/ingotCopper.png
  18. Is not so easy to make random block texture as before. From what I read you can simply generate one and apply it directly to a Block by using the methods before 1.8 which are still buried in the code but you need to create a fake json model with everything empty and you cannot add it to a creative tab. Is a hack but is not guaranteed is gonna work forever. in the json model you would have something like { "": { "": { "": "" } } } or some other bs system. I forget now. But there is a hacky way to do it. It only works for blocks.
  19. I thought I saw something where you had "facing=north, someproperty=value". with a space right after comma. I exaggerated to emphasize. Not sure if I saw that correctly. I'm pretty sure all properties need to be butted against one another "property=value,property2=value2" and anything like "property = value" will not work properly. Sometimes it may be something silly in json like you may be missing proper spaces or tabs etc. Since part of the modding is creating a resource pack for your mod.
  20. I remember reading that obj need to have proper normal /texture mapping .
  21. SOLVED see solution in UPDATE3 I have slowly figured out all there is to do including separate 1.9 like Block colorizer which actually works. But how do I turn on fancy transparent leaves? UPDATE: I have managed to make some headway but still not 100% sure exactly how this works. Something to do with UPDATE2: Further research suggests is something to do with leavesFancy boolean. Seems like is not set by Minecraft or Forge when I change settings. I need to figure out a different system to check if game is on fancy or not. UPDATE3: Figured it out guys. Looked around and finally found some example code in TinkersConstruct. The issue is what I thought above. The leavesFancy boolean is set to Block.LEAVES and Block.LEAVES2 ONLY. Any other mod or custom leaves need to simply copy steal anything regarding that boolean from one of those blocks like so: @Override @SideOnly(Side.CLIENT) public BlockRenderLayer getBlockLayer() { return Blocks.LEAVES.getBlockLayer(); } @Override public boolean isOpaqueCube(IBlockState state) { return Blocks.LEAVES.isOpaqueCube(state); }
  22. Sorry for the necro. Just wanted to mention Choonster is next level badass. I am using his 1.9 updated tutorial mod as example. Im a newb but I m making headway slowly . There is so much undocumented stuff. Anyway thanks for all the help thus far.
  23. 'm not sure what's going on but getStateFromMeta is necessary for the game to remember FACING or other blockstate property between game sessions. Without it the blocks reset to NORTH facing or whatever the default state is. But in Bock says is Deprecated but is not deprecated. Is obviously needed to make a block with different states. What gives? mind you I am using the newest halfstar 1.10 forge MDK 12.18.2.2105
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.