for beta 1.3.01!, just wait until 1.4 is updated peoples!
adding armor using MOD LOADER
*This tutorial does not teach you how to add a new enum material.
you wana make a custom looking armor. Obviously without texture packs
so you open up your mod_????.java (judging by you should have 1 by now)
Go to where all your items are defined! :biggrin.gif:
put this in
public static final Item SuperShirt = new
ItemArmor(ModLoader.getUniqueEntityId(), 4, ModLoader.AddArmor("SuperShirt"), 0)
so its a pretty long line
NOW LETS LEARN ! (this is unfun for most peoples)
Why
(ModLoader.getUniqueEntityId()?
because if this entity is spawned using a program like ssp commands. YOUR DOOMED. anyway im not even sure how to spawn it/give it a ID. Just leave it at that
Why
, 4,
This shows the armors power. In this case. Diamond. Dont go over it unless you have edited/created a new enummaterial
Why
("SuperShirt"), 0)
THIS PART IS IMPORTANT PEOPLES
Replace 0 with 1,2,3 or leave it at 0 0 = Helmet
1 = Chestplate
2 = Leggings
3 = Boots
Why
ModLoader.AddArmor("SuperShirt")
THIS PART IS IMPORTANT PEOPLES!
this will be the name of your png file, located in the armor folder in the minecraft.jar (Yah Cookies)
YOu need 2. So add this in your armor folder
SuperShirt_1.png
SuperShirt_2.png
Now add your textures of magical textures!
NOW TO FINISH IT OFF
Rainbow UNICORN
Make a crafting Recipe
Make a Icon
Equip it
BOOOOM your dononodneoneondoendonedodnodneondDOne
Excuse me if I do not speak English properly because I use a translation tool.
Here is my problem I created a block next to the day when my class is instantiated meteor, only it does not appear and no block my debug gives me Error meteor that mean that there is no empty space where I want it set for I is high
so I wonder if isAirBloc took good player's position x, y and z as parameter recover because I'm not sure.
My class is below to help you if its me
public class Meteore {
private Minecraft mc;
private EntityPlayerSP joueur;
private World monde;
public Meteore(Minecraft mc)
{
this.mc=mc;
this.joueur=this.mc.thePlayer;
this.monde=this.mc.theWorld;
this.init();
}
private void init()
{
joueur.sendChatMessage("---Meteorite activer---");
int x=joueur.chunkCoordX;
int y=joueur.chunkCoordY;
int z=joueur.chunkCoordZ;
x++;
y++;
z--;
System.out.println("log : "+x+" "+y+" "+z);
if(monde.isAirBlock(x, y, z))
{
monde.setBlock(x, y, z, 20);
}
else
{
System.out.println("Error meteore");
}
}
}
why are you using
this.mc=mc;
this.joueur=this.mc.thePlayer;
this.monde=this.mc.theWorld;
this.init();
in your code?
thats most likely causing it to not work
Hey, someone needs to make a tutorial on how to update your mods from Beta 1.3_01 to Beta 1.4. I tried to do this but even if I decompiled with the ModLoader files in my minecraft.jar, the modloader functions will give me recompiling errors. (All with MCP 2.1) Please help..
Ive made a new pickaxe again, ive made pickaxes before that have worked fine
i created a enum, for my own materials. applied it to my tools, and made 4 base files. Then testing ingame my shovel and axe, hoe work. However what dosent work is my pickaxe, it can't detect "Rock material" type blocks, like block.stone, so the speed is reduced to the same speed as my hands
i can put in blocks such as block.grass, it will harvest them faster, but blocks like block.cobblestone, it does not speed up at all. Ive never encountered this bug before, as ive made more pickaxes basically all the time.
It seems to affect all 3 of my pickaxes seem to prone to this bug/mistake
I need to know if there is a method that will tell me
what entity is detected, e.g. is it a creeper, a zombie, a skeleton, etc.
I've Googled a bit but i can't seem to find it.
(could it be entity.entityId? if so how do i use it?)
Can anyone help?
Thank you :DD
When you use any function that requires an entityliving, then you can use the instanceof keyword and then the class name for the creature you want.
I'm pretty new to Java, and I'm trying to work out which part of the Redstone Torch's code controls which blocks it powers. I already made an item based on the Redstone Torch, and successfully took out it's ability to power wires by removing this code:
public boolean isPoweringTo(IBlockAccess iblockaccess, int i, int j, int k, int l)
{
if(!torchActive)
{
return false;
}
int i1 = iblockaccess.getBlockMetadata(i, j, k);
if(i1 == 5 && l == 1)
{
return false;
}
if(i1 == 3 && l == 3)
{
return false;
}
if(i1 == 4 && l == 2)
{
return false;
}
if(i1 == 1 && l == 5)
{
return false;
}
return i1 != 2 || l != 4;
}
However, I doubt very much that is all there is to it. I am attempting to make an item that can power wire from a distance of 3 blocks instead of 1 (allowing for hidden circuits to be constructed with greater ease, as this can also power upwards), but I've been tinkering with it for a bit, and have not yet found a method that works. I tried running nested for loops in various places to no avail, could someone give me a hand with this? I'm a little stumped.
EDIT: I'm also having trouble finding where I can get into the world generator in order to add new ores and modify the stats of existing ones.
Im trying to add another sword into the game with this code
ackage net.minecraft.src;
public class ItemKatana extends Item
{
public ItemKatana(int i)
{
super(i);
maxDamage = 500;
maxStackSize = 1;
field_22047_d = 4;
}
public void hitEntity(ItemStack itemstack, EntityLiving entityliving)
{
itemstack.damageItem(1);
}
public void hitBlock(ItemStack itemstack, int i, int j, int k, int l)
{
itemstack.damageItem(2);
}
public int getDamageVsEntity(Entity entity)
{
return field_22047_d;
}
public boolean isFull3D()
{
return true;
}
public int field_22047_d;
}
but when i try to recompile i get this error:
*** Minecraft Coder Pack Version 2.10 ***
MCP 2.10 running in C:\Users\Daniel\Desktop\mcp
Compiling Minecraft
sources\minecraft\net\minecraft\src\ItemKatana.java:11: maxDamage has private ac
cess in net.minecraft.src.Item
maxDamage = 1800;
^
sources\minecraft\net\minecraft\src\ItemKatana.java:17: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(1);
^
sources\minecraft\net\minecraft\src\ItemKatana.java:22: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(2);
^
3 errors
*** minecraft_server.jar was not found, skipping
=== MCP 2.10 recompile script finished ===
Press any key to continue . . .
when trying to reobf the code i get this error plz help
*** Minecraft Coder Pack Version 2.10 ***
MCP 2.10 running in E:\MCp
+ Obfuscating client.
ERROR : Class file for net/minecraft/src/ not found. Please check your compilati
on logs for errors.
*** Server not compiled, skipping
=== MCP 2.10 reobfuscation script finished ===
Trykk en tast for å fortsette...
Can someone help me. I didn't have this problem in 1.3_01 when I recompiled and I haven't changed anything in the Item.java
*** Minecraft Coder Pack Version 2.10 ***
MCP 2.10 running in C:\Documents and Settings\Dakota\My Documents\Downloads\mcp2
10
Compiling Minecraft
sources\minecraft\net\minecraft\src\ItemToolGlowing.java:17: maxDamage has priva
te access in net.minecraft.src.Item
maxDamage = glowingtoolmaterial.getMaxUses();
^
sources\minecraft\net\minecraft\src\ItemToolGlowing.java:37: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(2);
^
sources\minecraft\net\minecraft\src\ItemToolGlowing.java:42: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(1);
^
sources\minecraft\net\minecraft\src\GlowHammer.java:13: maxDamage has private ac
cess in net.minecraft.src.Item
maxDamage = glowingtoolmaterial.getMaxUses();
^
sources\minecraft\net\minecraft\src\GlowHammer.java:24: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(2);
^
sources\minecraft\net\minecraft\src\GlowHammer.java:29: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(1);
^
sources\minecraft\net\minecraft\src\GlowHoe.java:15: maxDamage has private acces
s in net.minecraft.src.Item
maxDamage = glowingtoolmaterial.getMaxUses();
^
sources\minecraft\net\minecraft\src\GlowHoe.java:31: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(1);
^
sources\minecraft\net\minecraft\src\GlowPick.java:13: maxDamage has private acce
ss in net.minecraft.src.Item
maxDamage = 2000;
^
sources\minecraft\net\minecraft\src\GlowRod.java:14: maxDamage has private acces
s in net.minecraft.src.Item
maxDamage = 64;
^
sources\minecraft\net\minecraft\src\GlowRod.java:32: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(i);
^
sources\minecraft\net\minecraft\src\GlowSword.java:14: maxDamage has private acc
ess in net.minecraft.src.Item
maxDamage = glowingtoolmaterial.getMaxUses();
^
sources\minecraft\net\minecraft\src\GlowSword.java:25: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(1);
^
sources\minecraft\net\minecraft\src\GlowSword.java:30: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(2);
^
14 errors
*** minecraft_server.jar was not found, skipping
=== MCP 2.10 recompile script finished ===
Press any key to continue . . .
I need to know if there is a method that will tell me
what entity is detected, e.g. is it a creeper, a zombie, a skeleton, etc.
I've Googled a bit but i can't seem to find it.
(could it be entity.entityId? if so how do i use it?)
Can anyone help?
Thank you :DD
When you use any function that requires an entityliving, then you can use the instanceof keyword and then the class name for the creature you want.
For example:
if(entityliving instanceof EntityCreeper)
{
}
Thank you, I'll try that :biggrin.gif:
The reason i asked those questions is because i want to make a new block that is kind of like an open door, but only allows creepers to pass (it still looks like a normal block, not a door)
I got as far as figuring out what... thingy (lol i forgot the name, im a java newb) to use to detect when to go phantom and allow things to pass through;
onEntityCollidedWithBlock
But i have a more basic problem, i have created a mod_MoreTraps.java, and a BlockCreepersort.java.
In the mod_MoreTraps.java i have created a crafting recipe to create the BlockCreepersort.
But when i go in game and test it, the game runs fine, but then i try to craft it, and i put the crafting recipe into the crafting table, but to the right i can't click anything to create it.
I'm using mcp, modloader, minecraft beta 1.4 and eclipse helios.
I do think my code is fine but maybe its mcp, i heard it was not yet modloader compatible, is this true?
Or do i need to create an ItemCreepersort.java as well? (i just need to be able to place the block in-world, no fancy item-stuff required.)
-XDMickeYXD
Risu changed the way you add recipes with ModLoader. If you want to still be able to use your recipes without changing to the new way jsut add this line to your constructor. AddRecipes(CraftingMangager.getInstance()) and it will add the recipes when the mod is loaded.
Quote from grim3212 »
Can someone help me. I didn't have this problem in 1.3_01 when I recompiled and I haven't changed anything in the Item.java
*** Minecraft Coder Pack Version 2.10 ***
MCP 2.10 running in C:\Documents and Settings\Dakota\My Documents\Downloads\mcp2
10
Compiling Minecraft
sources\minecraft\net\minecraft\src\ItemToolGlowing.java:17: maxDamage has priva
te access in net.minecraft.src.Item
maxDamage = glowingtoolmaterial.getMaxUses();
^
sources\minecraft\net\minecraft\src\ItemToolGlowing.java:37: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(2);
^
sources\minecraft\net\minecraft\src\ItemToolGlowing.java:42: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(1);
^
sources\minecraft\net\minecraft\src\GlowHammer.java:13: maxDamage has private ac
cess in net.minecraft.src.Item
maxDamage = glowingtoolmaterial.getMaxUses();
^
sources\minecraft\net\minecraft\src\GlowHammer.java:24: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(2);
^
sources\minecraft\net\minecraft\src\GlowHammer.java:29: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(1);
^
sources\minecraft\net\minecraft\src\GlowHoe.java:15: maxDamage has private acces
s in net.minecraft.src.Item
maxDamage = glowingtoolmaterial.getMaxUses();
^
sources\minecraft\net\minecraft\src\GlowHoe.java:31: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(1);
^
sources\minecraft\net\minecraft\src\GlowPick.java:13: maxDamage has private acce
ss in net.minecraft.src.Item
maxDamage = 2000;
^
sources\minecraft\net\minecraft\src\GlowRod.java:14: maxDamage has private acces
s in net.minecraft.src.Item
maxDamage = 64;
^
sources\minecraft\net\minecraft\src\GlowRod.java:32: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(i);
^
sources\minecraft\net\minecraft\src\GlowSword.java:14: maxDamage has private acc
ess in net.minecraft.src.Item
maxDamage = glowingtoolmaterial.getMaxUses();
^
sources\minecraft\net\minecraft\src\GlowSword.java:25: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(1);
^
sources\minecraft\net\minecraft\src\GlowSword.java:30: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(2);
^
14 errors
*** minecraft_server.jar was not found, skipping
=== MCP 2.10 recompile script finished ===
Press any key to continue . . .
Notch removed that method in the last update. Theres a new one though I forget the name of it but check ItemStack. Its one you pass an int and an Entity.
Risu changed the way you add recipes with ModLoader. If you want to still be able to use your recipes without changing to the new way jsut add this line to your constructor. AddRecipes(CraftingMangager.getInstance()) and it will add the recipes when the mod is loaded.
Wait, maybe you can help me. How do I enable Modloader in MCP for MCP 2.10?
NOTE TO ALL WHO CANNOT READ: YES I KNOW THAT IN 2.9A THERE WAS AN ENABLE_MODLOADER SCRIPT, BUT I AM ASKING ABOUT THE NEW VERSION!
And can you also put up an example of how to add a new recipe with the new modloader in mcp?
Can someone help me. I didn't have this problem in 1.3_01 when I recompiled and I haven't changed anything in the Item.java
*** Minecraft Coder Pack Version 2.10 ***
MCP 2.10 running in C:\Documents and Settings\Dakota\My Documents\Downloads\mcp2
10
Compiling Minecraft
sources\minecraft\net\minecraft\src\ItemToolGlowing.java:17: maxDamage has priva
te access in net.minecraft.src.Item
maxDamage = glowingtoolmaterial.getMaxUses();
^
sources\minecraft\net\minecraft\src\ItemToolGlowing.java:37: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(2);
^
sources\minecraft\net\minecraft\src\ItemToolGlowing.java:42: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(1);
^
sources\minecraft\net\minecraft\src\GlowHammer.java:13: maxDamage has private ac
cess in net.minecraft.src.Item
maxDamage = glowingtoolmaterial.getMaxUses();
^
sources\minecraft\net\minecraft\src\GlowHammer.java:24: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(2);
^
sources\minecraft\net\minecraft\src\GlowHammer.java:29: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(1);
^
sources\minecraft\net\minecraft\src\GlowHoe.java:15: maxDamage has private acces
s in net.minecraft.src.Item
maxDamage = glowingtoolmaterial.getMaxUses();
^
sources\minecraft\net\minecraft\src\GlowHoe.java:31: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(1);
^
sources\minecraft\net\minecraft\src\GlowPick.java:13: maxDamage has private acce
ss in net.minecraft.src.Item
maxDamage = 2000;
^
sources\minecraft\net\minecraft\src\GlowRod.java:14: maxDamage has private acces
s in net.minecraft.src.Item
maxDamage = 64;
^
sources\minecraft\net\minecraft\src\GlowRod.java:32: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(i);
^
sources\minecraft\net\minecraft\src\GlowSword.java:14: maxDamage has private acc
ess in net.minecraft.src.Item
maxDamage = glowingtoolmaterial.getMaxUses();
^
sources\minecraft\net\minecraft\src\GlowSword.java:25: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(1);
^
sources\minecraft\net\minecraft\src\GlowSword.java:30: cannot find symbol
symbol : method damageItem(int)
location: class net.minecraft.src.ItemStack
itemstack.damageItem(2);
^
14 errors
*** minecraft_server.jar was not found, skipping
=== MCP 2.10 recompile script finished ===
Press any key to continue . . .
But, now I am having the same problem as XDMickeYXD. I can't craft anything. And I tried to add this
AddRecipes(CraftingMangager.getInstance())
and I get this
*** Minecraft Coder Pack Version 2.10 ***
MCP 2.10 running in C:\MCP
Compiling Minecraft
sources\minecraft\net\minecraft\src\mod_Glowtools.java:101: <identifier> expecte
d
public void AddRecipes(CraftingMangager.getInstance())
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:101: ';' expected
public void AddRecipes(CraftingMangager.getInstance())
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:101: illegal start of typ
e
public void AddRecipes(CraftingMangager.getInstance())
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:101: <identifier> expecte
d
public void AddRecipes(CraftingMangager.getInstance())
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:102: ';' expected
{
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:103: illegal start of typ
e
craftingmanager.addRecipe(new ItemStack(Pick, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:103: illegal start of typ
e
craftingmanager.addRecipe(new ItemStack(Pick, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:103: ')' expected
craftingmanager.addRecipe(new ItemStack(Pick, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:103: ';' expected
craftingmanager.addRecipe(new ItemStack(Pick, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:103: <identifier> expecte
d
craftingmanager.addRecipe(new ItemStack(Pick, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:103: <identifier> expecte
d
craftingmanager.addRecipe(new ItemStack(Pick, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:103: illegal start of typ
e
craftingmanager.addRecipe(new ItemStack(Pick, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:103: <identifier> expecte
d
craftingmanager.addRecipe(new ItemStack(Pick, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:103: ';' expected
craftingmanager.addRecipe(new ItemStack(Pick, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:103: <identifier> expecte
d
craftingmanager.addRecipe(new ItemStack(Pick, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:104: illegal start of typ
e
"###", " X ", " X ", Character.valueOf('#'), Ingot, Character.valueO
f('X'), Stick
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:104: <identifier> expecte
d
"###", " X ", " X ", Character.valueOf('#'), Ingot, Character.valueO
f('X'), Stick
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:104: ';' expected
"###", " X ", " X ", Character.valueOf('#'), Ingot, Character.valueO
f('X'), Stick
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:104: illegal start of typ
e
"###", " X ", " X ", Character.valueOf('#'), Ingot, Character.valueO
f('X'), Stick
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:104: <identifier> expecte
d
"###", " X ", " X ", Character.valueOf('#'), Ingot, Character.valueO
f('X'), Stick
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:104: ';' expected
"###", " X ", " X ", Character.valueOf('#'), Ingot, Character.valueO
f('X'), Stick
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:104: invalid method decla
ration; return type required
"###", " X ", " X ", Character.valueOf('#'), Ingot, Character.valueO
f('X'), Stick
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:104: illegal start of typ
e
"###", " X ", " X ", Character.valueOf('#'), Ingot, Character.valueO
f('X'), Stick
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:104: ';' expected
"###", " X ", " X ", Character.valueOf('#'), Ingot, Character.valueO
f('X'), Stick
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:105: class, interface, or
enum expected
});
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:106: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Axe, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:109: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Hoe, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:112: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Shovel, 1), new Object[]
{
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:115: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Sword, 1), new Object[]
{
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:118: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Pants, 1), new Object[]
{
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:121: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Helmet, 1), new Object[]
{
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:124: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Chest, 1), new Object[]
{
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:127: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Boots, 1), new Object[]
{
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:130: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Bow, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:133: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Arrow, 4), new Object[]
{
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:136: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Hammer, 1), new Object[]
{
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:139: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Torch, 4), new Object[]
{
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:142: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Starter, 4), new Object[
] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:145: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Handle, 1), new Object[]
{
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:148: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Rod, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:153: class, interface, or
enum expected
}
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:155: class, interface, or
enum expected
public String Version()
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:158: class, interface, or
enum expected
}
^
43 errors
*** minecraft_server.jar was not found, skipping
=== MCP 2.10 recompile script finished ===
Press any key to continue . . .
I'm having an issue with decompiling. It seems to skip everything..
File to patch:
Skip this patch? [y]
1 out of 1 hunk ignored
The text leading up to this was:
--------------------------
|diff -r net/minecraft/src/ThreadSleepForever.java
|--- a/net/minecraft/src/ThreadSleepForever.java Fri Feb 25 13:45:25 2011 +0100
|+++ b/net/minecraft/src/ThreadSleepForever.java Fri Feb 25 15:08:11 2011 +0100
--------------------------
File to patch:
Skip this patch? [y]
1 out of 1 hunk ignored
The text leading up to this was:
--------------------------
|diff -r net/minecraft/src/WorldBlockPositionType.java
|--- a/net/minecraft/src/WorldBlockPositionType.java Fri Feb 25 13:45:25 2011 +0100
|+++ b/net/minecraft/src/WorldBlockPositionType.java Fri Feb 25 15:08:11 2011 +0100
--------------------------
File to patch:
Skip this patch? [y]
1 out of 1 hunk ignored
The text leading up to this was:
--------------------------
|diff -r net/minecraft/src/Block.java
|--- a/net/minecraft/src/Block.java Fri Feb 25 15:08:11 2011 +0100
|+++ b/net/minecraft/src/Block.java Fri Feb 25 16:13:05 2011 +0100
--------------------------
File to patch:
Skip this patch? [y]
2 out of 2 hunks ignored
im having the same problem, I tried a fresh minecraft.jar and putting MCP somewhere different. nothing worked
Risu changed the way you add recipes with ModLoader. If you want to still be able to use your recipes without changing to the new way jsut add this line to your constructor. AddRecipes(CraftingMangager.getInstance()) and it will add the recipes when the mod is loaded.
Wait, maybe you can help me. How do I enable Modloader in MCP for MCP 2.10?
NOTE TO ALL WHO CANNOT READ: YES I KNOW THAT IN 2.9A THERE WAS AN ENABLE_MODLOADER SCRIPT, BUT I AM ASKING ABOUT THE NEW VERSION!
And can you also put up an example of how to add a new recipe with the new modloader in mcp?
You just decompile with it installed and the mappings he provides.
Quote from XDMickeYXD »
Quote from grim3212 »
Sadly, it didn't work. I got the same errors
*** Minecraft Coder Pack Version 2.10 ***
MCP 2.10 running in C:\MCP
Compiling Minecraft
sources\minecraft\net\minecraft\src\mod_Glowtools.java:101: <identifier> expecte
d
public void AddRecipes(CraftingManager.getInstance())
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:101: ';' expected
public void AddRecipes(CraftingManager.getInstance())
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:101: illegal start of typ
e
public void AddRecipes(CraftingManager.getInstance())
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:101: <identifier> expecte
d
public void AddRecipes(CraftingManager.getInstance())
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:102: ';' expected
{
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:103: illegal start of typ
e
craftingmanager.addRecipe(new ItemStack(Pick, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:103: illegal start of typ
e
craftingmanager.addRecipe(new ItemStack(Pick, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:103: ')' expected
craftingmanager.addRecipe(new ItemStack(Pick, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:103: ';' expected
craftingmanager.addRecipe(new ItemStack(Pick, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:103: <identifier> expecte
d
craftingmanager.addRecipe(new ItemStack(Pick, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:103: <identifier> expecte
d
craftingmanager.addRecipe(new ItemStack(Pick, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:103: illegal start of typ
e
craftingmanager.addRecipe(new ItemStack(Pick, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:103: <identifier> expecte
d
craftingmanager.addRecipe(new ItemStack(Pick, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:103: ';' expected
craftingmanager.addRecipe(new ItemStack(Pick, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:103: <identifier> expecte
d
craftingmanager.addRecipe(new ItemStack(Pick, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:104: illegal start of typ
e
"###", " X ", " X ", Character.valueOf('#'), Ingot, Character.valueO
f('X'), Stick
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:104: <identifier> expecte
d
"###", " X ", " X ", Character.valueOf('#'), Ingot, Character.valueO
f('X'), Stick
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:104: ';' expected
"###", " X ", " X ", Character.valueOf('#'), Ingot, Character.valueO
f('X'), Stick
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:104: illegal start of typ
e
"###", " X ", " X ", Character.valueOf('#'), Ingot, Character.valueO
f('X'), Stick
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:104: <identifier> expecte
d
"###", " X ", " X ", Character.valueOf('#'), Ingot, Character.valueO
f('X'), Stick
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:104: ';' expected
"###", " X ", " X ", Character.valueOf('#'), Ingot, Character.valueO
f('X'), Stick
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:104: invalid method decla
ration; return type required
"###", " X ", " X ", Character.valueOf('#'), Ingot, Character.valueO
f('X'), Stick
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:104: illegal start of typ
e
"###", " X ", " X ", Character.valueOf('#'), Ingot, Character.valueO
f('X'), Stick
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:104: ';' expected
"###", " X ", " X ", Character.valueOf('#'), Ingot, Character.valueO
f('X'), Stick
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:105: class, interface, or
enum expected
});
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:106: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Axe, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:109: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Hoe, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:112: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Shovel, 1), new Object[]
{
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:115: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Sword, 1), new Object[]
{
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:118: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Pants, 1), new Object[]
{
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:121: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Helmet, 1), new Object[]
{
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:124: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Chest, 1), new Object[]
{
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:127: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Boots, 1), new Object[]
{
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:130: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Bow, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:133: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Arrow, 4), new Object[]
{
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:136: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Hammer, 1), new Object[]
{
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:139: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Torch, 4), new Object[]
{
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:142: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Starter, 4), new Object[
] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:145: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Handle, 1), new Object[]
{
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:148: class, interface, or
enum expected
craftingmanager.addRecipe(new ItemStack(Rod, 1), new Object[] {
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:153: class, interface, or
enum expected
}
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:155: class, interface, or
enum expected
public String Version()
^
sources\minecraft\net\minecraft\src\mod_Glowtools.java:158: class, interface, or
enum expected
}
^
43 errors
*** minecraft_server.jar was not found, skipping
=== MCP 2.10 recompile script finished ===
Press any key to continue . . .
Thanks for your help though.
yw, i guess :smile.gif:
Yeah it doesn't work, i don't even know exactly what a constructor is, lol.
But i think i guessed right, but still, it doesn't work, here's my code, i think i'm doing something wrong...
package net.minecraft.src;
public class mod_MoreTraps extends BaseMod{
public String Version()
{
return "1.4";
}
@Override
public String func_25102_Version() {
// TODO Auto-generated method stub
return null;
}
public static final Block creepersort;
static
{
creepersort = (new BlockCreepersort (96,1)).setHardness(1.5F).setStepSound(Block.soundStoneFootstep);
}
public void AddRecipes(CraftingManager craftingmanager, CraftingManager.getInstance())
{
craftingmanager.addRecipe(new ItemStack(creepersort), new Object[]{"###","#X#","###",Character.valueOf('#'),Block.cobblestone,
Character.valueOf('X'),Item.gunpowder});
}
}
I myself got 27 errors rather than your 43;
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:18: <identifier> expected
public void AddRecipes(CraftingManager craftingmanager, CraftingManager.getInsta
nce())
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:18: ';' expected
public void AddRecipes(CraftingManager craftingmanager, CraftingManager.getInsta
nce())
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:18: illegal start of type
public void AddRecipes(CraftingManager craftingmanager, CraftingManager.getInsta
nce())
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:18: <identifier> expected
public void AddRecipes(CraftingManager craftingmanager, CraftingManager.getInsta
nce())
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:19: ';' expected
{
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:20: illegal start of type
craftingmanager.addRecipe(new ItemStack(creepersort), new Object[]{"###"
,"#X#","###",Character.valueOf('#'),Block.cobblestone,
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:20: illegal start of type
craftingmanager.addRecipe(new ItemStack(creepersort), new Object[]{"###"
,"#X#","###",Character.valueOf('#'),Block.cobblestone,
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:20: ')' expected
craftingmanager.addRecipe(new ItemStack(creepersort), new Object[]{"###"
,"#X#","###",Character.valueOf('#'),Block.cobblestone,
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:20: ';' expected
craftingmanager.addRecipe(new ItemStack(creepersort), new Object[]{"###"
,"#X#","###",Character.valueOf('#'),Block.cobblestone,
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:20: <identifier> expected
craftingmanager.addRecipe(new ItemStack(creepersort), new Object[]{"###"
,"#X#","###",Character.valueOf('#'),Block.cobblestone,
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:20: illegal start of type
craftingmanager.addRecipe(new ItemStack(creepersort), new Object[]{"###"
,"#X#","###",Character.valueOf('#'),Block.cobblestone,
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:20: <identifier> expected
craftingmanager.addRecipe(new ItemStack(creepersort), new Object[]{"###"
,"#X#","###",Character.valueOf('#'),Block.cobblestone,
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:20: ';' expected
craftingmanager.addRecipe(new ItemStack(creepersort), new Object[]{"###"
,"#X#","###",Character.valueOf('#'),Block.cobblestone,
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:20: illegal start of type
craftingmanager.addRecipe(new ItemStack(creepersort), new Object[]{"###"
,"#X#","###",Character.valueOf('#'),Block.cobblestone,
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:20: <identifier> expected
craftingmanager.addRecipe(new ItemStack(creepersort), new Object[]{"###"
,"#X#","###",Character.valueOf('#'),Block.cobblestone,
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:20: ';' expected
craftingmanager.addRecipe(new ItemStack(creepersort), new Object[]{"###"
,"#X#","###",Character.valueOf('#'),Block.cobblestone,
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:20: illegal start of type
craftingmanager.addRecipe(new ItemStack(creepersort), new Object[]{"###"
,"#X#","###",Character.valueOf('#'),Block.cobblestone,
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:20: <identifier> expected
craftingmanager.addRecipe(new ItemStack(creepersort), new Object[]{"###"
,"#X#","###",Character.valueOf('#'),Block.cobblestone,
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:20: ';' expected
craftingmanager.addRecipe(new ItemStack(creepersort), new Object[]{"###"
,"#X#","###",Character.valueOf('#'),Block.cobblestone,
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:20: illegal start of type
craftingmanager.addRecipe(new ItemStack(creepersort), new Object[]{"###"
,"#X#","###",Character.valueOf('#'),Block.cobblestone,
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:20: <identifier> expected
craftingmanager.addRecipe(new ItemStack(creepersort), new Object[]{"###"
,"#X#","###",Character.valueOf('#'),Block.cobblestone,
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:20: ';' expected
craftingmanager.addRecipe(new ItemStack(creepersort), new Object[]{"###"
,"#X#","###",Character.valueOf('#'),Block.cobblestone,
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:20: invalid method declar
ation; return type required
craftingmanager.addRecipe(new ItemStack(creepersort), new Object[]{"###"
,"#X#","###",Character.valueOf('#'),Block.cobblestone,
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:20: illegal start of type
craftingmanager.addRecipe(new ItemStack(creepersort), new Object[]{"###"
,"#X#","###",Character.valueOf('#'),Block.cobblestone,
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:20: ';' expected
craftingmanager.addRecipe(new ItemStack(creepersort), new Object[]{"###"
,"#X#","###",Character.valueOf('#'),Block.cobblestone,
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:21: class, interface, or
enum expected
Character.valueOf('X'),Item.gunpowder});
^
sources\minecraft\net\minecraft\src\mod_MoreTraps.java:22: class, interface, or
enum expected
}
^
27 errors
I hope someone can help us...
-XDMickeYXD
If this doesn't make sense i would really suggest you learn java. You need to call the method AddRecipes and pass it the CraftingManager instance to add your recipes.
I'm having an issue with decompiling. It seems to skip everything..
File to patch:
Skip this patch? [y]
1 out of 1 hunk ignored
The text leading up to this was:
--------------------------
|diff -r net/minecraft/src/ThreadSleepForever.java
|--- a/net/minecraft/src/ThreadSleepForever.java Fri Feb 25 13:45:25 2011 +0100
|+++ b/net/minecraft/src/ThreadSleepForever.java Fri Feb 25 15:08:11 2011 +0100
--------------------------
File to patch:
Skip this patch? [y]
1 out of 1 hunk ignored
The text leading up to this was:
--------------------------
|diff -r net/minecraft/src/WorldBlockPositionType.java
|--- a/net/minecraft/src/WorldBlockPositionType.java Fri Feb 25 13:45:25 2011 +0100
|+++ b/net/minecraft/src/WorldBlockPositionType.java Fri Feb 25 15:08:11 2011 +0100
--------------------------
File to patch:
Skip this patch? [y]
1 out of 1 hunk ignored
The text leading up to this was:
--------------------------
|diff -r net/minecraft/src/Block.java
|--- a/net/minecraft/src/Block.java Fri Feb 25 15:08:11 2011 +0100
|+++ b/net/minecraft/src/Block.java Fri Feb 25 16:13:05 2011 +0100
--------------------------
File to patch:
Skip this patch? [y]
2 out of 2 hunks ignored
im having the same problem, I tried a fresh minecraft.jar and putting MCP somewhere different. nothing worked
Are you using the newest MCP 2.10 and are decompiling a non-modded Beta 1.4 minecraft.jar
Does someone know the new methods for adding recipes and adding a monster spawning.
Since modloader updated I can't find them. Which sucks >.>
Thanks in advance
If his javadocs are updated i would suggest downloading them and looking at them. There are two methods to add an recipe. ModLoader.addRecipe or ModLoader.addShapelessRecipes. To add spawning theres like four so i would suggest looking at the decompiled modloader or his javadocs if they are updated
I'm having an issue with decompiling. It seems to skip everything..
File to patch:
Skip this patch? [y]
1 out of 1 hunk ignored
The text leading up to this was:
--------------------------
|diff -r net/minecraft/src/ThreadSleepForever.java
|--- a/net/minecraft/src/ThreadSleepForever.java Fri Feb 25 13:45:25 2011 +0100
|+++ b/net/minecraft/src/ThreadSleepForever.java Fri Feb 25 15:08:11 2011 +0100
--------------------------
File to patch:
Skip this patch? [y]
1 out of 1 hunk ignored
The text leading up to this was:
--------------------------
|diff -r net/minecraft/src/WorldBlockPositionType.java
|--- a/net/minecraft/src/WorldBlockPositionType.java Fri Feb 25 13:45:25 2011 +0100
|+++ b/net/minecraft/src/WorldBlockPositionType.java Fri Feb 25 15:08:11 2011 +0100
--------------------------
File to patch:
Skip this patch? [y]
1 out of 1 hunk ignored
The text leading up to this was:
--------------------------
|diff -r net/minecraft/src/Block.java
|--- a/net/minecraft/src/Block.java Fri Feb 25 15:08:11 2011 +0100
|+++ b/net/minecraft/src/Block.java Fri Feb 25 16:13:05 2011 +0100
--------------------------
File to patch:
Skip this patch? [y]
2 out of 2 hunks ignored
im having the same problem, I tried a fresh minecraft.jar and putting MCP somewhere different. nothing worked
Are you using the newest MCP 2.10 and are decompiling a non-modded Beta 1.4 minecraft.jar
yes i have an unmodded minecraft.jar and the latest MCP (2.10)
Something new involving Redstone has come up since my last request, and so I'm going to make a more general one:
Would someone mind going through how Redstone equipment interacts? I'm really unsure which bits of the code do what, and how powering blocks works from a programming perspective.
I'm doing this raw, by the way, not with Modloader.
I'm looking to, as I said before, create an item that transfers power 3 blocks instead of the normal Torch distance of 1 (though perhaps only upwards, since it would be unmanageable otherwise). I am also looking to create an item that will provide power indefinitely, without being turned off when a current flows through it, but I hope to make it a solid block, rather than a "torch" style object.
My aim here is to try and make the circuitry more realistic, part of which involves switches not activating unless there is power given to them first (which is the purpose of the aforementioned "battery" block). I think the easiest way to achieve all I want to is to get someone to talk me through how it all works in general. I've got the hang of most of the rest of it, I think, but Redstone still confuses the hell out of me. Anyone willing to give me a little help in understanding how the circuitry works has my sincerest thanks.
Oh, and as for my other problem, I managed to fix it by browsing through the files, and eventually stumbling upon the ChunkProviderGenerate.java file, and messing with some variables and numbers.
I have made a human mob in 1.3_01, but Spawnlist ain't for 1.4 yet... People say that spawnlist is in minecraft now, so what would I do??? I created it using Modloader 5 and Spawnlist...
for beta 1.3.01!, just wait until 1.4 is updated peoples!
adding armor using
MOD LOADER
*This tutorial does not teach you how to add a new enum material.
you wana make a custom looking armor. Obviously without texture packs
so you open up your mod_????.java (judging by you should have 1 by now)
Go to where all your items are defined! :biggrin.gif:
put this in
so its a pretty long line
NOW LETS LEARN ! (this is unfun for most peoples)
Why
(ModLoader.getUniqueEntityId()?
because if this entity is spawned using a program like ssp commands. YOUR DOOMED. anyway im not even sure how to spawn it/give it a ID. Just leave it at that
Why
, 4,
This shows the armors power. In this case. Diamond. Dont go over it unless you have edited/created a new enummaterial
Why
("SuperShirt"), 0)
THIS PART IS IMPORTANT PEOPLES
Replace 0 with 1,2,3 or leave it at 0
0 = Helmet
1 = Chestplate
2 = Leggings
3 = Boots
Why
ModLoader.AddArmor("SuperShirt")
THIS PART IS IMPORTANT PEOPLES!
this will be the name of your png file, located in the armor folder in the minecraft.jar (Yah Cookies)
YOu need 2. So add this in your armor folder
SuperShirt_1.png
SuperShirt_2.png
Now add your textures of magical textures!
NOW TO FINISH IT OFF
Rainbow UNICORN
Make a crafting Recipe
Make a Icon
Equip it
BOOOOM your dononodneoneondoendonedodnodneondDOne
why are you using
this.mc=mc;
this.joueur=this.mc.thePlayer;
this.monde=this.mc.theWorld;
this.init();
in your code?
thats most likely causing it to not work
Lots More Humans (Beta 1.5_01)
Ive made a new pickaxe again, ive made pickaxes before that have worked fine
i created a enum, for my own materials. applied it to my tools, and made 4 base files. Then testing ingame my shovel and axe, hoe work. However what dosent work is my pickaxe, it can't detect "Rock material" type blocks, like block.stone, so the speed is reduced to the same speed as my hands
i can put in blocks such as block.grass, it will harvest them faster, but blocks like block.cobblestone, it does not speed up at all. Ive never encountered this bug before, as ive made more pickaxes basically all the time.
It seems to affect all 3 of my pickaxes seem to prone to this bug/mistake
any solutions?
Yes, i have a MD tool's file, a enum for my materials.
When you use any function that requires an entityliving, then you can use the instanceof keyword and then the class name for the creature you want.
For example:
However, I doubt very much that is all there is to it. I am attempting to make an item that can power wire from a distance of 3 blocks instead of 1 (allowing for hidden circuits to be constructed with greater ease, as this can also power upwards), but I've been tinkering with it for a bit, and have not yet found a method that works. I tried running nested for loops in various places to no avail, could someone give me a hand with this? I'm a little stumped.
EDIT: I'm also having trouble finding where I can get into the world generator in order to add new ores and modify the stats of existing ones.
but when i try to recompile i get this error:
Have i forgotten to add a symbol somewhere?
https://assortedmods.com/
Risu changed the way you add recipes with ModLoader. If you want to still be able to use your recipes without changing to the new way jsut add this line to your constructor. AddRecipes(CraftingMangager.getInstance()) and it will add the recipes when the mod is loaded.
Notch removed that method in the last update. Theres a new one though I forget the name of it but check ItemStack. Its one you pass an int and an Entity.
Wait, maybe you can help me. How do I enable Modloader in MCP for MCP 2.10?
NOTE TO ALL WHO CANNOT READ: YES I KNOW THAT IN 2.9A THERE WAS AN ENABLE_MODLOADER SCRIPT, BUT I AM ASKING ABOUT THE NEW VERSION!
And can you also put up an example of how to add a new recipe with the new modloader in mcp?
But, now I am having the same problem as XDMickeYXD. I can't craft anything. And I tried to add this and I get this
https://assortedmods.com/
im having the same problem, I tried a fresh minecraft.jar and putting MCP somewhere different. nothing worked
http://www.minecraftforum.net/topic/252504-lens-blocks/
https://assortedmods.com/
You just decompile with it installed and the mappings he provides.
If this doesn't make sense i would really suggest you learn java. You need to call the method AddRecipes and pass it the CraftingManager instance to add your recipes.
Are you using the newest MCP 2.10 and are decompiling a non-modded Beta 1.4 minecraft.jar
If his javadocs are updated i would suggest downloading them and looking at them. There are two methods to add an recipe. ModLoader.addRecipe or ModLoader.addShapelessRecipes. To add spawning theres like four so i would suggest looking at the decompiled modloader or his javadocs if they are updated
yes i have an unmodded minecraft.jar and the latest MCP (2.10)
http://www.minecraftforum.net/topic/252504-lens-blocks/
Would someone mind going through how Redstone equipment interacts? I'm really unsure which bits of the code do what, and how powering blocks works from a programming perspective.
I'm doing this raw, by the way, not with Modloader.
I'm looking to, as I said before, create an item that transfers power 3 blocks instead of the normal Torch distance of 1 (though perhaps only upwards, since it would be unmanageable otherwise). I am also looking to create an item that will provide power indefinitely, without being turned off when a current flows through it, but I hope to make it a solid block, rather than a "torch" style object.
My aim here is to try and make the circuitry more realistic, part of which involves switches not activating unless there is power given to them first (which is the purpose of the aforementioned "battery" block). I think the easiest way to achieve all I want to is to get someone to talk me through how it all works in general. I've got the hang of most of the rest of it, I think, but Redstone still confuses the hell out of me. Anyone willing to give me a little help in understanding how the circuitry works has my sincerest thanks.
Oh, and as for my other problem, I managed to fix it by browsing through the files, and eventually stumbling upon the ChunkProviderGenerate.java file, and messing with some variables and numbers.