Jump to content

Recommended Posts

Posted
  On 1/17/2018 at 5:54 PM, leosavi25 said:

If I remove final when I try to enter in a world it says that ore_copper block and ore_copper item missing

Expand  

#AlwaysShowYourCode

  • Like 1

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.

Posted

Also, had you previously generated a world with your old code (which perhaps assigned different/corrupt values for block IDs).  I don't know exactly, but you may need to generate a new world if you aren't already doing so.

 

Posted
  Reveal hidden contents

Ok, I forgot to add BlockInit.preInit() and BlockInit.init() in the Main class, now the Item and the block there are, but the block doesn't smelting.

Posted
  On 1/17/2018 at 5:58 PM, ChronosWS said:

Also, had you previously generated a world with your old code (which perhaps assigned different/corrupt values for block IDs).  I don't know exactly, but you may need to generate a new world if you aren't already doing so.

 

Expand  

It doesn't work

Posted
  On 1/17/2018 at 6:12 PM, ChronosWS said:

For smelting, you might look here for an example of how to configure smelting:

https://github.com/Glitchfiend/BiomesOPlenty/blob/BOP-1.12.x-7.0.x/src/main/java/biomesoplenty/common/init/ModCrafting.java

 

in init(), you might do the following:

GameRegistry.addSmelting(new ItemStack(ORE_COPPER_BLOCK), new ItemStack(<your item or block here>), 0.1F);

if I understand the code correctly...

Expand  

I do it but it doesn't work

Posted
  On 1/17/2018 at 6:13 PM, leosavi25 said:

I do it but it doesn't work

Expand  

"Doctor, it hurts. What's wrong with me?"

 

Please describe the actual problem: what is the error you are getting, what is it that is not happening. Use your words. We aren't telepathic.

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.

Posted

You might find it very helpful to download the full source for one of these more established mods and step through it with a debugger.  Sometimes that's easier than reading the source (though in the case of the two mods I have linked so far, the source is pretty well organized.)

Posted
  On 1/16/2018 at 4:54 PM, leosavi25 said:

I dont't think that this is the problem: if I change BlockInit.ORE_COPPER_BLOCK with ItemInit.COPPER_INGOT and I put the Copper Ingot in the furnace it works and if I change it with Blocks.DIRT and I put a dirt block in the furnace it works. It doesn't work with BlockInit.ORE_COPPER_BLOCK. I try also to create another block and it doesn't work too. Could it be the BlockInit class that have some problem?

Expand  

If i try to smelt the ore copper it doesn't give me the ingot copper. Yesterday I write this, I don't know if you read this, but I think that it could be helpful

Posted
  On 1/17/2018 at 6:20 PM, ChronosWS said:

Is your sourcecode up on GitHub?  Can you post a link to the full source?  I feel like looking at your code through thin snippets is obscuring the actual problem.

Expand  

Oh it definitely is. Especially when it changes because "I forgot to call Blocks.Init()" and we have no idea what those snippets even look like now.

  • Like 1

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.

Posted (edited)

https://github.com/leosavi25/Modding/blob/master/src/main/java/com/leosavi25/mod/FactoryCraft.java#L32-L33

 

ADD SMELTING FOR MY ITEMS.

CREATE MY ITEMS.

THIS IS DEFINITELY THE RIGHT ORDER.

 

image.jpg

Edited by Draco18s
  • Like 1

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.

Posted

Yeah, you need to:

a) don't create BLOCK_COPPER in the static initializer

b) don't create your Items (in ItemsInit) in the static initializer.  Repeat the pattern of preInit and init from BlocksInit

c) call SmeltingInit after BlocksInit and ItemsInit (which you will need to add.)

 

Posted

I change the preInit method, BlockInit class and ItemInit class to this but it doen't work.

  Reveal hidden contents
  Reveal hidden contents
  Reveal hidden contents

 

Posted (edited)
  On 1/15/2018 at 2:45 PM, leosavi25 said:

I'm creating a mod for 1.12 and I add the Copper Ore and the Ingot Copper, but when I put the Copper Ore in the Furnace nothing happen.

Here's the code:

 

  Reveal hidden contents

 

Please help me!!!

Expand  

Where I can found the fml-client-latest.log file?

Edited by leosavi25
Posted
  Reveal hidden contents

 

Posted

I'm not seeing any errors in that log. And I suppose I should have clarified, if you're working in a development environment, the log will be in the run/logs directory of your project.

 

Also, you still haven't elaborated on "it doesn't work", which I believe people have already told you saying that with no further information is unhelpful.

Posted
  On 1/18/2018 at 2:51 PM, Ugdhar said:

I'm not seeing any errors in that log. And I suppose I should have clarified, if you're working in a development environment, the log will be in the run/logs directory of your project.

 

Also, you still haven't elaborated on "it doesn't work", which I believe people have already told you saying that with no further information is unhelpful.

Expand  

Yes, the log is in the development environment. Here the code: https://github.com/leosavi25/Modding

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  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.

Announcements




×
×
  • Create New...

Important Information

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