Sometimes when we create our armor we run into an issue where we can't put the armor onto the right area of our character. This could mean that you can only wear you boots on your head, or your helmet on your chest, or your chest plate on your feet. This happens when we get some of our parameters mixed up when declaring our armor. Our CustomArmor class has the following constructor.
public CustomArmor (String name, int renderIndex, int armorType) {
So when we create a new armor we must give it a name, renderIndex, and an armorType.
The renderIndex is 1 for all of the armors except for Leggings which has a render index of 2. The armor type follows the same order as the armor as we declare it or top to bottom from your player. The Helmet is on top so it is 0, then the chestplate is 1 and so on. This is what your armor declarations should look like.
myHelmet = new CustomArmor("myHelmet", 1, 0);
myChestplate = new CustomArmor("myChestplate", 1, 1);
myLeggings = new CustomArmor("myLeggings", 2, 2);
myBoots = new CustomArmor("myBoots", 1, 3);
Make sure that you inputs match with these and then run Minecraft again. If this does not work, just send a message to support and we will be happy to help.
Comments
0 comments
Please sign in to leave a comment.