Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

Posted

I'm adding in armor for my mod and I came across this: public static ArmorMaterial tin_helmet = EnumHelper.addArmorMaterial("tin_helmet", "mineralz", 125, 1, 30, soundOnEquip);

 

What am I supposed to do with soundOnEquip?

Has this something to do with the new sound whenever you equip yourself with gear?

If so where can I find the original sound of it?

soundOnEquip

is the

SoundEvent

to play when the armour is equipped, yes. Look at the

ArmorMaterial

enum itself to see which

SoundEvent

s are used by vanilla armour.

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

Use your IDE. In IntelliJ IDEA you can press Ctrl-N to bring up the Find Class window, this allows you to search for classes by name. Eclipse probably has a similar feature.

 

You can also browse the forgeSrc library in your IDE to find the

ItemArmor

class and the

ArmorMaterial

enum inside of it.

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

  • Author

I can't find any of it. Isn't eclipse supposed to have a copy of minecraft saved somewhere?

 

EDIT: Nvm found the source but where are the file sounds exactly located? That wizard can't do shiz...

Look for the

net.minecraft.item.ItemArmor

class inside the forgeSrc library.

 

If it doesn't have sources attached, you haven't set up your workspace properly. This page explains how to properly set up a ForgeGradle workspace.

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

  • Author

Ok i found it but now there's a new problem. I've been following a modding tutorial for 1.8.9 how to make your custom armor and this text keeps lighting up red.

 

public static ArmorMaterial tin_helmet = EnumHelper.addArmorMaterial("tin_helmet", "mineralz", 125, 3, 30, SoundEvents.item_armor_equip_iron);

 

now what?

If you mouseover the line with the error, Eclipse should tell you exactly what's wrong with it.

 

In this case, the arguments you're passing to

EnumHelper.addArmorMaterial

don't match its signature. Look at the

EnumHelper

class in your IDE to see the signature of the method.

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

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

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.