src\minecraft\net\minecraft\src\mod_Limestone.java:9: error: <identifier> expected
public static final Item ingotSteel = new (IngotSteel(128)).setIconIndex(ModLoader.addOverride("/gui/items.png", "/Procraft/Items/ingotSteel.png").setItemName("ingotSteel"));
^
You have the one after 128 and I added the other because of the one before Modloader
ok you're thing should look exactly like this:
public static final Item ingotSteel = new IngotSteel(128).setIconIndex(ModLoader.addOverride("/gui/items.png", "/ProCraft/Items/ingotSteel.png")).setItemName("ingotSteel");
I used this code and I got an error message from eclipse saying" Syntax error on token 'final' invalid type" and "pasta cannot be resolved to a variable." Also, when I remove the final, it says "pasta cannot be resolved to a variable", "pasta cannot be resolved to a type", "Illegal modifier for parameter $missing$; only final is permitted," and "Syntax error on token pasta, VariableDeclaratorId expected after this token." When I just put final it says "Syntax error on token 'final', invalid type" and "pasta cannot be resolved to a variable." Also my pasta looks like a leather cap. And yes I do have a file in the specified directory.
This is my mod_MoreFood code
package net.minecraft.src;
public class mod_MoreFood extends BaseMod
{
public mod_MoreFood()
{
public static final pasta = new FoodPasta(127, ModLoader.addOverride("/gui/items.png", "/mods/MoreFood/gui/items/Pasta.png")).setItemName("pasta");
}
public void load()
{
}
public String getVersion()
{
return "1.2.4";
}
}
This is my FoodPasta code.
package net.minecraft.src;
public class FoodPasta extends ItemFood
{
public FoodPasta(int i, int j)
{
super(i, j, true);
}
}
you're item declaration should go ABOVE 'public mod_MoreFood'
also you can't say pasta after final because that's not the name of one of your classes
you should probably say Item instead of pasta
also you're second variable you're inputting shouldn't be the texture
here's what it should all look like (i'm assuming you don't want it to be wolf's favorite food which is why it says false):
mod_MoreFood:
package net.minecraft.src;
public class mod_MoreFood extends BaseMod
{
public static final Item pasta = new FoodPasta(127, 4).setIconIndex(ModLoader.addOverride("/gui/items.png", "/mods/MoreFood/gui/items/Pasta.png")).setItemName("pasta");
public mod_MoreFood()
{
}
public void load()
{
}
public String getVersion()
{
return "1.2.4";
}
}
the 4 is the healing amount
FoodPasta:
package net.minecraft.src;
public class FoodPasta extends ItemFood
{
public FoodPasta(int i, int j)
{
super(i, j, false);
}
}
Props for not using EnumToolMaterial for your tool sets. It makes me mad how people don't take 5 more minutes to figure out that C+P a file to your own isn't hard.
you're item declaration should go ABOVE 'public mod_MoreFood'
also you can't say pasta after final because that's not the name of one of your classes
you should probably say Item instead of pasta
also you're second variable you're inputting shouldn't be the texture
here's what it should all look like (i'm assuming you don't want it to be wolf's favorite food which is why it says false):
mod_MoreFood:
package net.minecraft.src;
public class mod_MoreFood extends BaseMod
{
public static final Item pasta = new FoodPasta(127, 4).setIconIndex(ModLoader.addOverride("/gui/items.png", "/mods/MoreFood/gui/items/Pasta.png")).setItemName("pasta");
public mod_MoreFood()
{
}
public void load()
{
}
public String getVersion()
{
return "1.2.4";
}
}
the 4 is the healing amount
FoodPasta:
package net.minecraft.src;
public class FoodPasta extends ItemFood
{
public FoodPasta(int i, int j)
{
super(i, j, false);
}
}
Whenever I use the gen ore tut I get a red X mark error in eclipse on this part. new WorldGenMinable(oreTitanium.blockID, 4)
It says this The constructor WorldGenMinable(int, int) is undefined.
public class mod_SteelCraft extends BaseMod
{
public static final Block oreTitanium = new BlockTitaniumOre(128, 0).setHardness(3F).setResistance(5000F).setStepSound(Block.soundStoneFootstep).setBlockName("Titanium Ore");
public static final Item ingotSteel = (new ItemingotSteel(129).setItemName("Steel Ingot"));
public static final Item pickaxeSteel = (new ItemSteelPickaxe(130, ToolMaterial. STEEL)).setItemName("Steel Pickaxe");
public static final Item hoeSteel = (new ItemSteelHoe(131, ToolMaterial. STEEL)).setItemName("Steel Hoe");
public static final Item axeSteel = (new ItemSteelAxe(132, ToolMaterial. STEEL)).setItemName("Steel Axe");
public static final Item shovelSteel = (new ItemSteelShovel(133, ToolMaterial. STEEL)).setItemName("Steel Shovel");
public static final Item swordSteel = (new ItemSteelSword(134, ToolMaterial. STEEL)).setItemName("Steel Sword");
public void load()
{
oreTitanium.blockIndexInTexture = ModLoader.addOverride("/terrain.png", "/mods/Titanium.png");
ingotSteel.iconIndex = ModLoader.addOverride("/gui/items.png", "/mods/icon1.png");
pickaxeSteel.iconIndex = ModLoader.addOverride("/gui/items.png", "/mods/SteelPickaxe.png");
hoeSteel.iconIndex = ModLoader.addOverride("/gui/items.png", "/mods/Steelhoe.png");
axeSteel.iconIndex = ModLoader.addOverride("/gui/items.png", "/mods/Steelaxe.png");
shovelSteel.iconIndex = ModLoader.addOverride("/gui/items.png", "/mods/SteelShovel.png");
swordSteel.iconIndex = ModLoader.addOverride("/gui/items.png", "/mods/SteelSword.png");
ModLoader.addName(ingotSteel, "Steel Ingot");
ModLoader.addName(pickaxeSteel, "Steel Pickaxe");
ModLoader.addName(hoeSteel, "Steel Hoe");
ModLoader.addName(axeSteel, "Steel Axe");
ModLoader.addName(shovelSteel, "Steel Shovel");
ModLoader.addName(swordSteel, "Steel Sword");
ModLoader.addName(oreTitanium, "Titanium Ore");
ModLoader.registerBlock(oreTitanium);
}
public void GenerateSurface(World world, Random rand, int chunkX, int chunkZ)
{
for(int l = 0; l < 4; l++)
{
int i1 = chunkX + rand.nextInt(16);
int j1 = rand.nextInt(14);
int k1 = chunkZ + rand.nextInt(16);
new WorldGenMinable(oreTitanium, 8).generate(world, rand, i1, j1, k1);
My textures go in eclipse/client/bin/mods and I still got the same problem after trying your piece of code I stated earlier of this part having this error. (new WorldGenMinable(oreTitanium, 8)) The constructor WorldGenMinable(Block, int) is undefined
I'm having a problem with your ModLoader armor tutorials, I made armor that is stronger than diamond. When I test it in Minecraft it's as strong as leather armor.
When I change -
super(i, EnumArmorMaterial.CLOTH, j, k);
to
super(i, EnumArmorMaterial.DIAMOND, j, k);
it makes it as strong as diamond. How do I make it the material it should be? I tried changing EnumArmorMaterial to my ModEnumAmorMaterial, but that just causes an error since ItemArmor's parameter involves EnumArmorMaterial. I don't know if you still look at these comments but I would really appriciate the help, thank you!
ok you're thing should look exactly like this:
as far as the parentheses go
This is my mod_MoreFood code
This is my FoodPasta code.
What am I doing wrong?
http://www.minecraftforum.net/topic/1237692-125-lordofcatss-mods-defenders-of-steve-and-more/page__fromsearch__1
also you can't say pasta after final because that's not the name of one of your classes
you should probably say Item instead of pasta
also you're second variable you're inputting shouldn't be the texture
here's what it should all look like (i'm assuming you don't want it to be wolf's favorite food which is why it says false):
mod_MoreFood:
the 4 is the healing amount
FoodPasta:
show me your error log and your code
Thanks!
http://www.minecraftforum.net/topic/1237692-125-lordofcatss-mods-defenders-of-steve-and-more/page__fromsearch__1
i have no experience with making mods
It says this The constructor WorldGenMinable(int, int) is undefined.
you're doing something else wrong besides that
import net.minecraft.src.forge.*;
import java.util.*;
import java.util.Random;
public class mod_SteelCraft extends BaseMod
{
public static final Block oreTitanium = new BlockTitaniumOre(128, 0).setHardness(3F).setResistance(5000F).setStepSound(Block.soundStoneFootstep).setBlockName("Titanium Ore");
public static final Item ingotSteel = (new ItemingotSteel(129).setItemName("Steel Ingot"));
public static final Item pickaxeSteel = (new ItemSteelPickaxe(130, ToolMaterial. STEEL)).setItemName("Steel Pickaxe");
public static final Item hoeSteel = (new ItemSteelHoe(131, ToolMaterial. STEEL)).setItemName("Steel Hoe");
public static final Item axeSteel = (new ItemSteelAxe(132, ToolMaterial. STEEL)).setItemName("Steel Axe");
public static final Item shovelSteel = (new ItemSteelShovel(133, ToolMaterial. STEEL)).setItemName("Steel Shovel");
public static final Item swordSteel = (new ItemSteelSword(134, ToolMaterial. STEEL)).setItemName("Steel Sword");
public void load()
{
oreTitanium.blockIndexInTexture = ModLoader.addOverride("/terrain.png", "/mods/Titanium.png");
ingotSteel.iconIndex = ModLoader.addOverride("/gui/items.png", "/mods/icon1.png");
pickaxeSteel.iconIndex = ModLoader.addOverride("/gui/items.png", "/mods/SteelPickaxe.png");
hoeSteel.iconIndex = ModLoader.addOverride("/gui/items.png", "/mods/Steelhoe.png");
axeSteel.iconIndex = ModLoader.addOverride("/gui/items.png", "/mods/Steelaxe.png");
shovelSteel.iconIndex = ModLoader.addOverride("/gui/items.png", "/mods/SteelShovel.png");
swordSteel.iconIndex = ModLoader.addOverride("/gui/items.png", "/mods/SteelSword.png");
ModLoader.addName(ingotSteel, "Steel Ingot");
ModLoader.addName(pickaxeSteel, "Steel Pickaxe");
ModLoader.addName(hoeSteel, "Steel Hoe");
ModLoader.addName(axeSteel, "Steel Axe");
ModLoader.addName(shovelSteel, "Steel Shovel");
ModLoader.addName(swordSteel, "Steel Sword");
ModLoader.addName(oreTitanium, "Titanium Ore");
ModLoader.registerBlock(oreTitanium);
}
public void GenerateSurface(World world, Random rand, int chunkX, int chunkZ)
{
for(int l = 0; l < 4; l++)
{
int i1 = chunkX + rand.nextInt(16);
int j1 = rand.nextInt(14);
int k1 = chunkZ + rand.nextInt(16);
new WorldGenMinable(oreTitanium, 8).generate(world, rand, i1, j1, k1);
ModLoader.addRecipe(new ItemStack(ingotSteel, 1), new Object[] {"XXX", "###", "@@@", Character.valueOf('X'), Block.sand, Character.valueOf('#'), Item.ingotIron, Character.valueOf('@'), Item.coal
});
ModLoader.addRecipe(new ItemStack(pickaxeSteel), new Object[] {"XXX", " @ ", " @ ", Character.valueOf('X'), Item.pickaxeDiamond, Character.valueOf('@'), ingotSteel
});
ModLoader.addRecipe(new ItemStack(hoeSteel), new Object[] {"XX ", " @ ", " @ ", Character.valueOf('X'), Item.hoeDiamond, Character.valueOf('@'), ingotSteel
});
ModLoader.addRecipe(new ItemStack(axeSteel), new Object[] {"XX ", "X@ ", " @ ", Character.valueOf('X'), Item.axeDiamond, Character.valueOf('@'), ingotSteel
});
ModLoader.addRecipe(new ItemStack(shovelSteel), new Object[] {" X ", " @ ", " @ ", Character.valueOf('X'), Item.shovelDiamond, Character.valueOf('@'), ingotSteel
});
ModLoader.addRecipe(new ItemStack(swordSteel), new Object[] {" X ", " X ", " @ ", Character.valueOf('X'), Item.swordDiamond, Character.valueOf('@'), ingotSteel
});}
}
public void addCreativeItems(ArrayList itemList)
{
for(int l1 = 0; l1 < 2; l1++)
{
itemList.add(new ItemStack(pickaxeSteel, 1, l1));
}
}
public void addCreativeItems2(ArrayList itemList)
{
for(int l1 = 0; l1 < 2; l1++)
{
itemList.add(new ItemStack(axeSteel, 1, l1));
}
}
public void addCreativeItems3(ArrayList itemList)
{
for(int l1 = 0; l1 < 2; l1++)
{
itemList.add(new ItemStack(shovelSteel, 1, l1));
}
}
public void addCreativeItems4(ArrayList itemList)
{
for(int l1 = 0; l1 < 2; l1++)
{
itemList.add(new ItemStack(hoeSteel, 1, l1));
}
}
public void addCreativeItems5(ArrayList itemList)
{
for(int l1 = 0; l1 < 2; l1++)
{
itemList.add(new ItemStack(swordSteel, 1, l1));
}
}
public String getVersion()
{
return "1.2.5";
}
make sure to put the last two brackets and the parentheses around the thingy
i meant to say change oreTitanium to oreTitanium.blockId (or blockID idk which one it is)
EDIT: chnaged it to oreTitanium.blockID : 128, 8 and I still get the undefined error.
When I change - to it makes it as strong as diamond. How do I make it the material it should be? I tried changing EnumArmorMaterial to my ModEnumAmorMaterial, but that just causes an error since ItemArmor's parameter involves EnumArmorMaterial. I don't know if you still look at these comments but I would really appriciate the help, thank you!