Now when I compile I am getting errors with EntityHorse even though I haven't edited it, Fix? Or should I just get rid of it?
Why Have You Decompiled A Bin With a Mod In It (was It To Study The Mod? If So Why Are You Recompiling?)
If Your Just Wanting To Study The Mo' Creatures Class Files And Make A Mod Seperate The .class I Have a Folder on My Desktop With Those In It To Study Later But The One I Make Mods With Is A Clean Bin Folder Decompiled Which Is Recommed Because Having a Mod In Deletes The META Folder Which It Looks For
Mickey,
What im trying to ask is how do i create blocks after 1.2_2, since i believe the code has changed.
I was using the "Creating a new block" tutorial and i cant seem to find that line of code.
The tutorial probably is out-dated, so, how do i create new blocks after 1.2_2?
BAMP!
I see no whole bunch of declarations.
public static final Block example; is the line im trying to find where to put...
How do you get a new ore block you've created to generate in the world?
its in the ChunkProviderGenerate file in the populate section you will see like dirt diamond iron select one of them depending on how common so dirt most common diamond least common copy that bit of code for example iron :
for(int j3 = 0; j3 < 20; j3++)
{
int k6 = k + rand.nextInt(16);
int l9 = rand.nextInt(64);
int j14 = l + rand.nextInt(16);
(new WorldGenMinable(Block.oreIron.blockID, 8)).generate(worldObj, rand, k6, l9, j14);
}
and change Block.oreIron.blockID to the same your block
hope it helps
CAN SOMEONE PLZ HELP ME
ive created a new throw able object and i copied the EntityArrow coding exactly renamed it to my object
and instead of being an arrow its a white box
how do i set an image for the entity so that its not a white box
How do you get a new ore block you've created to generate in the world?
its in the ChunkProviderGenerate file in the populate section you will see like dirt diamond iron select one of them depending on how common so dirt most common diamond least common copy that bit of code for example iron :
for(int j3 = 0; j3 < 20; j3++)
{
int k6 = k + rand.nextInt(16);
int l9 = rand.nextInt(64);
int j14 = l + rand.nextInt(16);
(new WorldGenMinable(Block.oreIron.blockID, 8)).generate(worldObj, rand, k6, l9, j14);
}
and change Block.oreIron.blockID to the same your block
hope it helps
I'll try this right now!
---
Alright, I am getting a message saying "^sources\minecraft\net\minecraft\src\BlockSalt.java:26: class, interface, or enum expected" when trying to re-compile my mod.
Here's my BlockSalt .java file:
package net.minecraft.src;
import java.util.Random;
public class BlockSalt extends Block
{
public BlockSalt(int i, int j)
{
super(i, j, Material.rock);
}
}
public int idDropped(int i, Random random)
{
if(blockID == Block.Salt.blockID)
{
return Item.salt.shiftedIndex;
}
}
public int quantityDropped(Random random)
{
return 4 + random.nextInt(2);
}
Alright, I am getting a message saying "^sources\minecraft\net\minecraft\src\BlockSalt.java:26: class, interface, or enum expected" when trying to re-compile my mod.
Here's my BlockSalt .java file:
package net.minecraft.src;
import java.util.Random;
public class BlockSalt extends Block
{
public BlockSalt(int i, int j)
{
super(i, j, Material.rock);
}
}
public int idDropped(int i, Random random)
{
if(blockID == Block.Salt.blockID)
{
return Item.salt.shiftedIndex;
}
}
public int quantityDropped(Random random)
{
return 4 + random.nextInt(2);
}
What's wrong?
You need to add } at the bottom ... and delete one at line 13
public mod_roadsmod()
{
ModLoader.RegisterBlock(dirt);
ModLoader.AddName(dirtRoad, "Dirt ");
}
Take this out.
1. You don't need to do RegisterBlock. Modloader does that for you.
2. AddName should be in it's own function, I think called 'AddAllNames' or something like that.
3. You are declaring mod_roadsmon() for no reason at all. It's not a constructor because your class name is 'mod_mymod', and so nothing is calling this. Also, it has no return type, I can't remember if that is valid in Java or not...
This is so frustrating! I keep getting the same error with ItemSalt above no matter what I change in the .java file. Everything is named correctly, so I don't understand why it's giving me that error!
This is so frustrating! I keep getting the same error with ItemSalt above no matter what I change in the .java file. Everything is named correctly, so I don't understand why it's giving me that error!
Alright Guys I Really Need Your Help Here.
So Im Making A mod Its Called The PortableGrill Its Just Like The Furnace But Can Be Crafted In the 2x2 Inventory CraftingBench With 2 Cobble And 1 Torch Although It Will Take It Longer To Cook.
Ive Fixed Everything But What Lies In Block.java Heres My error
sources\minecraft\net\minecraft\src\Block.java:708: cannot find symbol
symbol : variable PortableGrillIdle
location : class net.minecraft.src.Block
PortableGrillOvenIdle = (new blockPortable Grill(77, true)).setHardness(0.5F).setStepSound(soundStoneFootsteps).func_20012_a("PortableGrill");
^
sources\minecraft\net\minecraft\src\Block.java:709: cannot find symbol
symbol : variable PortableGrillActive
location : class net.minecraft.src.Block
PortableGrillActive = (new blockPortable Grill(78, true)).setHardness(0.5F).setStepSound(soundStoneFootsteps).setLightValue(0.875F).func_20012_a("PortableGrill");
^
If They Moved The First ^ Was Pointing At The ) in SetHardness(0.5f)
The other Was Pointing To The End of("PortableGrill");
I Copied The Furnaces Code And Jst Changed It and The 77 true and 78 True Are Pointing At Costume .PGNs in .Terrian
what do i do if i want a costum texture for my block?
in the block.java file where i have the properties for the block, i have somthing like this (1{id of block}, 13{texture number in the terrain.png}
so if i create my own texture and put it in an empty space in the terrain.png how do i know the number of the empty space I've chose??
MatrexsVigil:
You need a return type (like, void, int, etc.) after "public" and before "ItemFood". You can't declare a function without a return type.
Minecraftstudio:
The line here is wrong.
PortableGrillOvenIdle = (new blockPortable Grill(77, true)).setHardness(0.5F).setStepSound(soundStoneFootsteps).func_20012_a("PortableGrill");
It should be something like:
PortableGrillOvenIdle = (new WhateverYourCustomClassIsCalledHERE(77, true)).setHardness(0.5F).setStepSound(soundStoneFootsteps).func_20012_a("PortableGrill");
You had "blockPortable Grill" which is incorrect. You can't have a space in that line and it can't be declared as two different objects.
And added a 1 on to EntityCreeper, but I'm doubting you have even defined EntityCreeper1... Is that your custom creeper class? What part of this code is yours?
...And the error code would probably be more useful here than you might think.
FYI, if anyone here wants help post your error codes. Copy + Paste. It's not that hard and it helps people to determine your problem a lot easier.
Yosi56:
The texture blocks (16x16 pixels each) go in order from 0-15 left to right, and 0-15 top to bottom.
So if you put a texture that is 8 blocks right and 8 blocks down, you would use the coordinates (7, 7).
Why 7s and not 8s? Because you start counting at 0. :smile.gif:
PortableGrillOvenIdle = (new blockPortable Grill(77, true)).setHardness(0.5F).setStepSound(soundStoneFootsteps).func_20012_a("PortableGrill");
It should be something like:
PortableGrillOvenIdle = (new WhateverYourCustomClassIsCalledHERE(77, true)).setHardness(0.5F).setStepSound(soundStoneFootsteps).func_20012_a("PortableGrill");
You had "blockPortable Grill" which is incorrect. You can't have a space in that line and it can't be declared as two different objects.
Thanks For Helping But I Relized That Was A Typeo On My Part The real error code had no space inbetween new blockPortableGrill I typed new blockPortable Grill.
So I Still Get The Error
Why Have You Decompiled A Bin With a Mod In It (was It To Study The Mod? If So Why Are You Recompiling?)
If Your Just Wanting To Study The Mo' Creatures Class Files And Make A Mod Seperate The .class I Have a Folder on My Desktop With Those In It To Study Later But The One I Make Mods With Is A Clean Bin Folder Decompiled Which Is Recommed Because Having a Mod In Deletes The META Folder Which It Looks For
The Maze Adventure Map
http://www.youtube.com/user/Wiz909090
BAMP!
I see no whole bunch of declarations.
public static final Block example; is the line im trying to find where to put...
its in the ChunkProviderGenerate file in the populate section you will see like dirt diamond iron select one of them depending on how common so dirt most common diamond least common copy that bit of code for example iron :
for(int j3 = 0; j3 < 20; j3++)
{
int k6 = k + rand.nextInt(16);
int l9 = rand.nextInt(64);
int j14 = l + rand.nextInt(16);
(new WorldGenMinable(Block.oreIron.blockID, 8)).generate(worldObj, rand, k6, l9, j14);
}
and change Block.oreIron.blockID to the same your block
hope it helps
ive created a new throw able object and i copied the EntityArrow coding exactly renamed it to my object
and instead of being an arrow its a white box
how do i set an image for the entity so that its not a white box
For ex. i created a block like this
And i created mod_mymod like this:
It's all what i did.What i have to do next and are there any errors or smthing that i forgot about?
I'll try this right now!
---
Alright, I am getting a message saying "^sources\minecraft\net\minecraft\src\BlockSalt.java:26: class, interface, or enum expected" when trying to re-compile my mod.
Here's my BlockSalt .java file:
What's wrong?
You need to add } at the bottom ... and delete one at line 13
Take this out.
1. You don't need to do RegisterBlock. Modloader does that for you.
2. AddName should be in it's own function, I think called 'AddAllNames' or something like that.
3. You are declaring mod_roadsmon() for no reason at all. It's not a constructor because your class name is 'mod_mymod', and so nothing is calling this. Also, it has no return type, I can't remember if that is valid in Java or not...
*smacks forehead* Thank you!
You'd think I'd know this having sorta learned other programing languages. Oye.
Ontopic: this is a great source of info ill probably dable in this later
sources\minecraft\net\minecraft\src\ItemSalt.java:5: invalid method declaration;
return type required
public ItemFood(int i);
^
1 error
"return type required"...
So Im Making A mod Its Called The PortableGrill Its Just Like The Furnace But Can Be Crafted In the 2x2 Inventory CraftingBench With 2 Cobble And 1 Torch Although It Will Take It Longer To Cook.
Ive Fixed Everything But What Lies In Block.java Heres My error
If They Moved The First ^ Was Pointing At The ) in SetHardness(0.5f)
The other Was Pointing To The End of("PortableGrill");
I Copied The Furnaces Code And Jst Changed It and The 77 true and 78 True Are Pointing At Costume .PGNs in .Terrian
The Maze Adventure Map
http://www.youtube.com/user/Wiz909090
in the block.java file where i have the properties for the block, i have somthing like this (1{id of block}, 13{texture number in the terrain.png}
so if i create my own texture and put it in an empty space in the terrain.png how do i know the number of the empty space I've chose??
please help :smile.gif:
[simg]http://i.min.us/ievcu8.png[/simg]
You need a return type (like, void, int, etc.) after "public" and before "ItemFood". You can't declare a function without a return type.
Minecraftstudio:
The line here is wrong.
It should be something like:
You had "blockPortable Grill" which is incorrect. You can't have a space in that line and it can't be declared as two different objects.
tijmen707:
You changed this line:
And added a 1 on to EntityCreeper, but I'm doubting you have even defined EntityCreeper1... Is that your custom creeper class? What part of this code is yours?
...And the error code would probably be more useful here than you might think.
FYI, if anyone here wants help post your error codes. Copy + Paste. It's not that hard and it helps people to determine your problem a lot easier.
Yosi56:
The texture blocks (16x16 pixels each) go in order from 0-15 left to right, and 0-15 top to bottom.
So if you put a texture that is 8 blocks right and 8 blocks down, you would use the coordinates (7, 7).
Why 7s and not 8s? Because you start counting at 0. :smile.gif:
Thanks For Helping But I Relized That Was A Typeo On My Part The real error code had no space inbetween new blockPortableGrill I typed new blockPortable Grill.
So I Still Get The Error
The Maze Adventure Map
http://www.youtube.com/user/Wiz909090