
nedas60
Forge Modder-
Posts
23 -
Joined
-
Last visited
Converted
-
Gender
Undisclosed
-
Personal Text
Let's code! Why not?
Recent Profile Visitors
The recent visitors block is disabled and is not being shown to other users.
nedas60's Achievements

Tree Puncher (2/8)
0
Reputation
-
[1.10.2] [SOLVED]Potion effect when full set is worn. Where do I put it?
nedas60 replied to nedas60's topic in Modder Support
Oh wait sorry forgot to update the title. This is now fixed. Previously in the comment I said didn't notice that the effectPlayer or whatever it is was in a method. Also bedrock's design was a bit broken. I had to fix it up a bit. Now it is fixed -
[1.10.2] [SOLVED]Potion effect when full set is worn. Where do I put it?
nedas60 replied to nedas60's topic in Modder Support
That does come from a tutorial and it is an enum. -
[1.10.2] [SOLVED]Potion effect when full set is worn. Where do I put it?
nedas60 replied to nedas60's topic in Modder Support
I have learned java. What I have NOT learned is minecraft's functions and stuff like that. What can I do? Sure sometimes people don't see mistakes. I didn't notice that he made it differently. That's why I am here. -
[1.10.2] [SOLVED]Potion effect when full set is worn. Where do I put it?
nedas60 replied to nedas60's topic in Modder Support
Well blame the tutorial -
[1.10.2] [SOLVED]Potion effect when full set is worn. Where do I put it?
nedas60 replied to nedas60's topic in Modder Support
I am kinda new to forge. Who knows how it works. Please don't judge I also tried following BedrockMiner's tutorial and I seem to be getting an error. Code: package Nedas60.TestMod.items; import Nedas60.TestMod.Reference; import Nedas60.TestMod.init.ModItems; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.init.MobEffects; import net.minecraft.inventory.EntityEquipmentSlot; import net.minecraft.item.ItemArmor; import net.minecraft.item.ItemStack; import net.minecraft.potion.Potion; import net.minecraft.potion.PotionEffect; import net.minecraft.world.World; public class Infused_Leggings extends ItemArmor { public Infused_Leggings(ArmorMaterial material) { super(material, 2, EntityEquipmentSlot.LEGS); setUnlocalizedName(Reference.TestItems.INFUSED_LEGGINGS.getUnlocalizedName()); setRegistryName(Reference.TestItems.INFUSED_LEGGINGS.getRegistryName()); } @Override public void onArmorTick(World world, EntityPlayer player, ItemStack itemStack) { private void effectPlayer(EntityPlayer player1, Potion potionIn, int amplifier) { //Always effect for 8 seconds, then refresh if (player1.getActivePotionEffect(potionIn) == null || player1.getActivePotionEffect(potionIn).getDuration() <= 1) player1.addPotionEffect(new PotionEffect(Potion.getActivePotionEffect(potionIn)), 159, amplifier, true, true)); } if (player1.inventory.armorItemInSlot(3) != null && player1.inventory.armorItemInSlot(3).getItem() == ModItems.InfusedHelmet && player1.inventory.armorItemInSlot(2) != null && player1.inventory.armorItemInSlot(2).getItem() == ModItems.InfusedBoots && player1.inventory.armorItemInSlot(1) != null && player1.inventory.armorItemInSlot(1).getItem() == ModItems.InfusedLeggings && player1.inventory.armorItemInSlot(0) != null && player1.inventory.armorItemInSlot(0).getItem() == ModItems.InfusedChestplate) { this.effectPlayer(player, MobEffects.SPEED, 3); } } } But there are a lot of errors. Can someone explain how can I get it to work normally? Errors: Multiple markers at this line - void is an invalid type for the variable effectPlayer - Syntax error on token ",", ; expected - Syntax error on token "(", ; expected - Syntax error on token ")", ; expected - Syntax error on token ",", ; expected That's not all: Multiple markers at this line - The method addPotionEffect(PotionEffect) in the type EntityLivingBase is not applicable for the arguments (PotionEffect, int, int, boolean, boolean) - The method getActivePotionEffect(Potion) is undefined for the type Potion - Syntax error on token ")", delete this token Also: The method effectPlayer(EntityPlayer, Potion, int) is undefined for the type Infused_Leggings -
[1.10.2] [SOLVED]Potion effect when full set is worn. Where do I put it?
nedas60 replied to nedas60's topic in Modder Support
Which classes are you talking about? You only posted one so far. All of the armor ones. The difference between them is just the name and the super value. There is Infused_Helmet, Infused_Leggings, Infused_Boots, Infused_Chestplate. -
[1.10.2] [SOLVED]Potion effect when full set is worn. Where do I put it?
nedas60 replied to nedas60's topic in Modder Support
Sorry if it unclear. It said "test for armor set" Do I put that for each class or just one of my choice? -
I have a class for each individual armor item. Code looks like: package Nedas60.TestMod.items; import net.minecraft.item.ItemArmor; import Nedas60.TestMod.Reference; import net.minecraft.inventory.EntityEquipmentSlot; import net.minecraft.item.Item; public class Infused_Leggings extends ItemArmor { public Infused_Leggings(ArmorMaterial material) { super(material, 2, EntityEquipmentSlot.LEGS); setUnlocalizedName(Reference.TestItems.INFUSED_LEGGINGS.getUnlocalizedName()); setRegistryName(Reference.TestItems.INFUSED_LEGGINGS.getRegistryName()); } } Ofcourse each one has it's own names. The problem is that I don't know where to put the test for armor set. Should I create a new class?
-
[1.10.2] How add custom armor? (I am new to forge)
nedas60 replied to nedas60's topic in Modder Support
Works perfectly now! Got confused a bit:D -
[1.10.2] How add custom armor? (I am new to forge)
nedas60 replied to nedas60's topic in Modder Support
Still doesn't seem to work. I have it in the src\main\resources\assets\ntm\models\armor folder. Is there anything wrong here? -
[1.10.2] How add custom armor? (I am new to forge)
nedas60 replied to nedas60's topic in Modder Support
It seems to render as a black box. Do I need to add something to the class? package Nedas60.TestMod.items; import net.minecraft.item.ItemArmor; import Nedas60.TestMod.Reference; import net.minecraft.inventory.EntityEquipmentSlot; import net.minecraft.item.Item; public class Infused_Helmet extends ItemArmor { public Infused_Helmet(ArmorMaterial material) { super(material, 1, EntityEquipmentSlot.HEAD); // - Sets item texture when in hand and in inventory + some other stuff setUnlocalizedName(Reference.TestItems.INFUSED_HELMET.getUnlocalizedName()); setRegistryName(Reference.TestItems.INFUSED_HELMET.getRegistryName()); } } And the Armor material I have is: public static ArmorMaterial INFUSED_ARMOR = EnumHelper.addArmorMaterial("INFUSED_ARMOR", "ntm:textures/models/armor/Test", 200, new int[] {4, 9, 7, 4}, 30, SoundEvents.ITEM_ARMOR_EQUIP_DIAMOND, 5.0F); -
[1.10.2] How add custom armor? (I am new to forge)
nedas60 replied to nedas60's topic in Modder Support
Thanks but how do I add the texture to the ArmorMaterial? That is the main problem for me. It gives an error without it. -
[1.10.2] How add custom armor? (I am new to forge)
nedas60 replied to nedas60's topic in Modder Support
I want to create armor with the infused armor material. I have the textures. I don't have the code for the class and I don't see any tutorials with MrCrayfish's setup. -
[1.10.2] How add custom armor? (I am new to forge)
nedas60 replied to nedas60's topic in Modder Support
Thanks but I actually want the code not the textures:D -
I tried searching tutorials but most of them had the setup where you type LONG lines to register the item. I also don't understand how to add the textures (Do they have to be in the same package?). I used MrCrayfish's setup ( ) and I want to know how do you add armor with his registering setup. I have the line: public static ArmorMaterial INFUSED_ARMOR = EnumHelper.addArmorMaterial("INFUSED_ARMOR", (I also dont understand how to add the textures), 200, new int[] {4, 9, 7, 4}, 30, SoundEvents.ITEM_ARMOR_EQUIP_DIAMOND, 5.0F); Thanks!