Jump to content

How do I make my custom tool be repaired with vanilla items?


epicool

Recommended Posts

8 minutes ago, diesieben07 said:

Override getIsRepairable in your Item class.

I do not know how to do that. Is it ItemList.java or ToolMaterialList.java

 

I believed I needed to change something with 'ItemList.tutorial_item' from 'diamond(6.0f, 8.0f, 1561, 1, 10, ItemList.tutorial_item);'

Link to comment
Share on other sites

1 hour ago, epicool said:

ItemList.java or ToolMaterialList.java

Is ItemList a class that extends Item? Is ToolMaterialList?

No?

Go find your class that extends Item.

  • Thanks 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.

Link to comment
Share on other sites

No.

Some tips:

Spoiler

Modder Support:

Spoiler

1. Do not follow tutorials on YouTube, especially TechnoVision (previously called Loremaster) and HarryTalks, due to their promotion of bad practice and usage of outdated code.

2. Always post your code.

3. Never copy and paste code. You won't learn anything from doing that.

4. 

Quote

Programming via Eclipse's hotfixes will get you nowhere

5. Learn to use your IDE, especially the debugger.

6.

Quote

The "picture that's worth 1000 words" only works if there's an obvious problem or a freehand red circle around it.

Support & Bug Reports:

Spoiler

1. Read the EAQ before asking for help. Remember to provide the appropriate log(s).

2. Versions below 1.11 are no longer supported due to their age. Update to a modern version of Minecraft to receive support.

 

 

Link to comment
Share on other sites

10 minutes ago, DavidM said:

Do not follow tutorials on YouTube

Sadly, this is what I was doing. But I have no clue what to do when I'm not using a tutorial.

10 minutes ago, DavidM said:

Programming via Eclipse's hotfixes will get you nowhere

What do you mean by this?

10 minutes ago, DavidM said:

Learn to use your IDE, especially the debugger.

If you are talking about the debug option next to the run option, neither of them work

 

The main question I'm asking is how can I learn to mod Minecraft?

 

Link to comment
Share on other sites

4 minutes ago, epicool said:

Sadly, this is what I was doing. But I have no clue what to do when I'm not using a tutorial.

What do you mean by this?

If you are talking about the debug option next to the run option, neither of them work

 

The main question I'm asking is how can I learn to mod Minecraft?

 

That is my signature. Those are not directed at you specifically, but are general tips for new modders.

 

If the debugger is not working for you, you might want to check your setup.

 

Thr best way to learn to mod Minecraft is to read vanilla code and check out other mods' code on GitHub.

  • Thanks 1

Some tips:

Spoiler

Modder Support:

Spoiler

1. Do not follow tutorials on YouTube, especially TechnoVision (previously called Loremaster) and HarryTalks, due to their promotion of bad practice and usage of outdated code.

2. Always post your code.

3. Never copy and paste code. You won't learn anything from doing that.

4. 

Quote

Programming via Eclipse's hotfixes will get you nowhere

5. Learn to use your IDE, especially the debugger.

6.

Quote

The "picture that's worth 1000 words" only works if there's an obvious problem or a freehand red circle around it.

Support & Bug Reports:

Spoiler

1. Read the EAQ before asking for help. Remember to provide the appropriate log(s).

2. Versions below 1.11 are no longer supported due to their age. Update to a modern version of Minecraft to receive support.

 

 

Link to comment
Share on other sites

1 hour ago, epicool said:

But I am not able to get cobblestone or any type of wood planks as repair materials.

Use Block#asItem. Blocks are in net.minecraft.block.Blocks.

About Me

Spoiler

My Discord - Cadiboo#8887

My WebsiteCadiboo.github.io

My ModsCadiboo.github.io/projects

My TutorialsCadiboo.github.io/tutorials

Versions below 1.14.4 are no longer supported on this forum. Use the latest version to receive support.

When asking support remember to include all relevant log files (logs are found in .minecraft/logs/), code if applicable and screenshots if possible.

Only download mods from trusted sites like CurseForge (minecraft.curseforge.com). A list of bad sites can be found here, with more information available at stopmodreposts.org

Edit your own signature at www.minecraftforge.net/forum/settings/signature/ (Make sure to check its compatibility with the Dark Theme)

Link to comment
Share on other sites

10 minutes ago, Cadiboo said:

Use Block#asItem. Blocks are in net.minecraft.block.Blocks.

Aren't the item form of blocks present in the static list in Items? I would swear that they were (but will accept fever-dream explanations).

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.

Link to comment
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.
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.