Whenever I get a chance to finish it. I'm away from home for a few days, plus haven't been feeling to well either. It could be either later today, or in a few days - I just don't know right now.
I'm on tutorial 15a and I got a few errors trying to import some things
The error for "Class": Class is a raw type. References to generic type Class<T> should be parameterized
The error for "instance":instance cannot be resolved or is not a field
My textures are not showing up, but no errors show up so that's a plus;)
package CheeseCore.items; import cpw.mods.fml.relauncher.Side; import cpw.mods.fml.relauncher.SideOnly; import net.minecraft.client.renderer.texture.IIconRegister; import net.minecraft.creativetab.CreativeTabs; import net.minecraft.item.Item; import CheeseCore.help.Reference; public class MMitem extends Item { public MMitem() { super(); setCreativeTab(CreativeTabs.tabMisc); } @SideOnly(Side.CLIENT) @Override public void registerIcons(IIconRegister par1IconRegister) { itemIcon = par1IconRegister.registerIcon(Reference.MODID + ":" + getUnlocalizedName().substring(5));
}
}
package CheeseCore.init;
import net.minecraft.item.Item; import CheeseCore.help.RegisterHelper; import CheeseCore.items.MMitem; public class ModItems { public static Item cheese = new MMitem().setUnlocalizedName("cheese"); public static void init() { RegisterHelper.registerItem(cheese); }
}
I can continue with the tutorial so this is not a major issue but if anyone figures it out let me know
so where would i go to find the source code for vanilla minecraft
You will not have the entire source code for things like apples, bread, etc, but you will have all the files you need.
Where to find Src:
build\tmp\recompSrc
build.tmp.recompSrc
You will start figuring out things yourself on modding if you put yourself up to it. I find modding easier than making a java game from scratch because you can read and understand the files instead of making your own not knowing what to do. Knowing java isn't enough.
Where would my commands go in the MainRegistry? How do I figure out what goes in PreLoad, load, and PostLoad?
You mean methods. If you're registering any fluids, items, blocks or so, those go in pre-initialization. If you have anything to do with these registered blocks, items and whatnot, for example, building structures, recipes, you put them in initialization. Some mod authors use post initialization to gather data from other mods, to see if they're loaded, to see if some items were enabled or disabled, etc.
Thanks!
now this has a problem though,
public static Item cheese = new MMItem().setUnlocalizedName("cheese");
I think is has to do with my RegisterHelper class though:
package CheeseCore.help;
import cpw.mods.fml.common.registry.GameRegistry;
import net.minecraft.block.Block;
import net.minecraft.item.Item;
import CheeseCore.init.ModItems;
public class RegisterHelper {
public static void registerBlock(Block block)
{
GameRegistry.registerBlock(block, Reference.MODID + block.getUnlocalizedName().substring(5));
}
public static void registerItem(Item item)
{
GameRegistry.registerItem(item, Reference.MODID + item.getUnlocalizedName().substring(5));
}
}
What am I supposed to name my item texture?
Is there anything special that I need to name it for the game to recognize it?
Because I'm pretty sure I followed all the steps in the tutorial.
Thanks for the help.
Have you created the MMItem class?
Whatever the unlocalized name is.
LOL I continued witht the tutorial and it worked! I thought because it said all errors were supposed to be fixed I did something wrong.:P
Any Idea whats wrong with this one :
package blocks;
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
public class Blockcheesebrick extends Block
{
public Blockcheesebrick()
{
super(Material.iron);
}
}
By the way I did follow the entire tutorial this time
Why is your package "blocks"? By the way, I recommend naming your class "BlockCheeseBrick", and not making its material iron.
Anyone know when the next tutorial comes out?
Whenever I get a chance to finish it. I'm away from home for a few days, plus haven't been feeling to well either. It could be either later today, or in a few days - I just don't know right now.
Get well soon!
I made the package blocks because the tutorial said to...
Does anyone actually know whats wrong with it?
The package's name is wrong. It should be "whateveryourmainclasspackageis.blocks"
The reason for this is because the tutorial said you must put the blocks package INSIDE that package.
Example, cuz I'm sure you didn't get it:
Thanks, I thought it was a little weird that the name was different than the rest but the tutorial said to name it blocks so I did.
I'm on tutorial 15a and I got a few errors trying to import some things
The error for "Class": Class is a raw type. References to generic type Class<T> should be parameterized
The error for "instance":instance cannot be resolved or is not a field
Where would my commands go in the MainRegistry? How do I figure out what goes in PreLoad, load, and PostLoad?
so where would i go to find the source code for vanilla minecraft
My textures are not showing up, but no errors show up so that's a plus;)package CheeseCore.items;import cpw.mods.fml.relauncher.Side;import cpw.mods.fml.relauncher.SideOnly;import net.minecraft.client.renderer.texture.IIconRegister;import net.minecraft.creativetab.CreativeTabs;import net.minecraft.item.Item;import CheeseCore.help.Reference;public class MMitem extends Item{public MMitem(){super();setCreativeTab(CreativeTabs.tabMisc);}@SideOnly(Side.CLIENT)@Overridepublic void registerIcons(IIconRegister par1IconRegister){itemIcon = par1IconRegister.registerIcon(Reference.MODID + ":" + getUnlocalizedName().substring(5));}}package CheeseCore.init;import net.minecraft.item.Item;import CheeseCore.help.RegisterHelper;import CheeseCore.items.MMitem;public class ModItems{public static Item cheese = new MMitem().setUnlocalizedName("cheese");public static void init(){RegisterHelper.registerItem(cheese);}}I can continue with the tutorial so this is not a major issue but if anyone figures it out let me knowNever-mind capital letters in the wrong place lol
You will not have the entire source code for things like apples, bread, etc, but you will have all the files you need.
Where to find Src:
build\tmp\recompSrc
build.tmp.recompSrc
You will start figuring out things yourself on modding if you put yourself up to it. I find modding easier than making a java game from scratch because you can read and understand the files instead of making your own not knowing what to do. Knowing java isn't enough.
Follow the tutorials to setup everything.
You mean methods. If you're registering any fluids, items, blocks or so, those go in pre-initialization. If you have anything to do with these registered blocks, items and whatnot, for example, building structures, recipes, you put them in initialization. Some mod authors use post initialization to gather data from other mods, to see if they're loaded, to see if some items were enabled or disabled, etc.
Hey, First of all, thanks for the awesome tutorials!
I'm working my way through #4 right now, and I found a syntax error that you might want to know about:
***CURRENTLY
setCreativeTab(CreativeTab.tabBlocks);
*** It should read--I believe (2 errors - 's' is in the wrong place)
setCreativeTab(CreativeTabs.tabBlock);
----------------------------------------^-------------^
Thanks again, I am really enjoying these!!!
So I want to make a custom mod for my modpack, how would I go about making a mod with only events no blocks or items.
Dragon(s) Yay!