Hey this is Asyncronous, please call me Leah for those people that can't spell my online name, as Leah is my real name. I decided to make tutorials on how to make mods with Minecraft Forge 6.x. Please note that the following tutorials are not basic tutorials and are going to cover some hard topics, they probably (mostly) require a lot of classes. If you have barely any experience making basic things in java then these tutorials are probably not for you. If anyone have any suggestions on what I should do please post below or p.m. me.
-------------Thanks---------------
To Mojang - For creating the amazing game that we all play.
To The Minecraft Forge Team (Past & Present) - For Making Forge
To drinfernoo (I think I spelled that right) - For helping in my extended absences
To Direwolf20 - For getting me into Minecraft / Minecraft Modding in the first place
--------------Addendum-----------------
1.) I am a grammar Nazi, so be forewarned
2.) Be polite please, I know I can't make you but I will ignore you, and I ask all those who aren't being rude to ignore the ones who are. Rudeness gets you nowhere.
3.) If you have a suggestion on another tutorial to add to the poll, post it below
API:
For some odd reason I got this requested a few times from people, they wanted to know how to make an API. So to make it simple because I can't really show you how to make one because really APIs are just a collection of code that may help you when making the finale product. So I'm really only going to say that, and this: if you want to make an API then come up with the idea for the API is it going to be like the dimension API or is it going to be like chicken bones's chicken core and just help your code or add universal features. Then just make the code on how you want it, without making a mod file (unless you want to sometimes its better) and whenever you want to use it just import it.
For all those who requested this and want an example or someone who wants an example then post about it or message me about it and Ill see about making an example.
Armor:
TutorialArmor.java:
TutorialArmor.java:
package asyncronous.tutorials;
import net.minecraft.src.EnumArmorMaterial;
import net.minecraft.src.ItemArmor;
import net.minecraft.src.ItemStack;
import net.minecraftforge.common.IArmorTextureProvider;
// This Is Your Class For Your Armor, Your Have To Extend ItemArmor For Minecraft To Register(Have The Required Methods And Values) This As Armor
// Then You Need To Implement IArmorTextureProvider For It To Be Able To Render
public class TutorialArmor extends ItemArmor implements IArmorTextureProvider{
// This Is Your Constructor, The First Param Is Item ID, The Second Is Its Material, The Third Is The Rendering ID, and The Final Is The Type (i.e. Helmet, Plate, Boots, Legs)
public TutorialArmor(int par1, EnumArmorMaterial par2EnumArmorMaterial, int par3, int par4){
super(par1, par2EnumArmorMaterial, par3, par4);
}
// This Sets What The Armor Is Supposed To Render Like
@Override
public String getArmorTextureFile(ItemStack stack){
if(stack.itemID == <ArmorHelmet>.shiftedIndex || stack.itemID == <ArmorPlate>.shiftedIndex || stack.itemID == <ArmorBoots>.shiftedIndex){
return <PathToArmorTextureFile_1>;
}
if(stack.itemID == <ArmorLegs>.shiftedIndex>){
return <PathToArmorTextureFile_2>;
}
}
// This Sets The Icon For The Item Inside The Inventory
@Override
public String getTextureFile(){
return <PathToIconTexture>;
}
}
Your Mod File:
To Get The Rendering ID:
public static final int renderSilver = proxy.addArmor("silver");
For Boots:
public static Item boots = (new TutorialArmor(5000, EnumArmorMaterial.IRON, renderSilver, 3).setItemName("boots").setCreativeTab(CreativeTabs.tabCombat);
For Helmet:
public static Item helmet = (new TutorialArmor(5000, EnumArmorMaterial.IRON, renderSilver, 0)).setItemName("helmet").setCreativeTab(CreativeTabs.tabCombat));
For Plate:
public static Item plate = (new TutorialArmor(5000, EnumArmorMaterial.IRON, renderSilver, 1)).setItemName("plate").setCreativeTab(CreativeTabs.tabCombat);
For Leggings:
public static Item legs = (new TutorialArmor(5000, EnumArmorMaterial.IRON, renderSilver, 2)).setItemName("legs").setCreativeTab(CreativeTabs.tabCombat);
In Your Common Proxy:
Add The Following Method:
public int addArmor(String armorName){
return 0;
}
In Your Client Proxy:
Override The addArmor Method From The CommonProxy:
@Override
public int addArmor(String armorName){
return RenderinRegistry.addArmourRendererPrefix(armorName);
}
Dimension:
From now on btw all my tutorials are going on this site: www.minecraftforgetutorials.weebly.com
its a joint tutorial website set up by DarkHax & jcm(something comes after this I just don't remember) they asked me if I would be willing to help out, so I said yes.
They also have nice tutorials floating around the MC forums, so check them out, I will post links sometime soon to them. but here is the tutorial: http://minecraftforg...n-tutorial.html
Tools:
Coming Soon
Audio Tutorials:
In The Core @Mod() File:
Add the following method to you @PreInit Method:
MinecraftForge.EVENT_BUS.register(new <The Name For Your @Mod Class>);
Then you are going to need to make a new method in here:
@ForgeSubscribe
public void onSound(SoundLoadEvent event){
try{
event.manager.soundPoolSounds.addSound("<Core @Mod File Name>/<name>.ogg", <Your @Mod FileName>.class.getResource("<Path To The File">));
} catch(Exception exception){
System.err.println("Failed To Register Sound: " + exception.getMessage());
}
}
In The Item / Block That Plays The Sound File:
In The onBlockActivated() Method or the onItemRightClick() Method add the following line + what ever else you have in there:
world.playSoundAtEntity(<The EntityPlayer Reference>, "<Core @Mod File Name>.<Reference Name I.E gunshot or burp or broken_bone>", <The Volume In Floating Decimal point (Float [.F])>, <The Pitch In Floating Decimal Point(Float [F]);
Biomes & Biome Generation:
In The Core @Mod File:
Add The Following Object Declaration To The File:
public static final BiomeGenBase <Name Of Object> = new <Name Of Class That Extends Biome Gen Base I.E BiomegenSuperPlains>(<Registry Number I.E This Is Where The Object Is Registered In The Matrices Of The BiomeGenList[]>).setBiomeName(<This Would Be You Biome Name>).setColor(<This Would Be Your Color For It Mostly Done In Hex>);
In The @Init Method Add:
GameRegistry.addBiome(<BiomeGenBase Object You Created Above>);
Next Make A New Class That Extends BiomeGenBase Example:
// This Is My Package Declaration And Everything Applies To Before With This
package aits.core.common;
// You Don't Need This If You Have package net.minecraft.src;
import net.minecraft.src.*;
public class BiomeGenSuperPlains extends BiomeGenBase{
public BiomeGenSuperPlains(int id){
super(id);
// This Is The Top Five Or So Blocks, Remember The Java Byte Rule: No Byte Is Above 127
topBlock = (byte) Block.cobblestonemossy.blockID;
// This Is The Rest Of The Blocks, Again The Java Byte Rule
fillerBlock = (byte) Block.cobblestone.blockID;
}
}
I am using Forge's Gui Handler, but I can't make it work , Maybe it is in my Block class, but I'm not sure, the total thing is anew Furnace, but with 2 input slots, if that helps.
~YoWazzup, or Kees
There's also a really good container GUI tutorial on MinecrafForge's wiki, here
For a furnace with two (or more ) inputs, you want to make a recipe that uses a HashMap with an ItemStack[] array as its input, and a single ItemStack as an output, and just check to make sure both items in the array are present in your furnace slots. There a tutorial on a furnace with two outputs here, but I guess that's sort of backwards
I just wrote one, but while posting this, I realized it could be coded _alot_ better, so I'll maybe post the source when I'm done.
Thank you too I'd really like to see some tutorials on hooks, more details on the whole NetworkMod thing (how it works, not just c&p), and tools/armor. Another cool one would be for new mobs.
I really hope these come soon Asyncronous, It seems like all of 1.3.2 Forge tutorials I can find are for "your first block" and "your first item", which, admittedly, are a little too simple for me by now
Let me know if I can help at all
Rollback Post to RevisionRollBack
Learn some Java before you mod, and skip over the chapter on ModLoader, straight to MinecraftForge. It's better. Trust me.
I'm gonna follow this topic, could always come in usefull
Also, something I'd love to see is how to make a gui without a TileEntity, but with an item or something.
I've made a GUI which opens using keybindings, without the need of a TileEntity.
hehe, I already have the code and stuf, and i don't use hash maps, i use sortof the same way as normal frunaces, but two ints instead of one. If you're interested look here: http://www.github.co...azzup/CocoCraft
!!! Modloader !!! Let me go get my cross So, what exactly was the problem? The GUI doesn't open?
I'm gonna follow this topic, could always come in usefull
Also, something I'd love to see is how to make a gui without a TileEntity, but with an item or something.
I've made a GUI which opens using keybindings, without the need of a TileEntity.
You only need a TileEntity if it's going to be a Container (chest, furnace, crafting table, etc...). You can register a TileEntity with an Item, though, if I'm not mistaken.
Rollback Post to RevisionRollBack
Learn some Java before you mod, and skip over the chapter on ModLoader, straight to MinecraftForge. It's better. Trust me.
You only need a TileEntity if it's going to be a Container (chest, furnace, crafting table, etc...). You can register a TileEntity with an Item, though, if I'm not mistaken.
As far as I know, you can make a TileEntity for anything, as it's just an entity, so it doesn't have to have a block or other physical object bound to it.
I'm getting a bad attention-***** vibe from this thread. A tutorial thread that includes more "I'm a girl, look at me. I even have pictures to prove it" than tutorials? I'm sorry if I'm offending everyone and in case there will actually be tutorials, I'd really like to see a tutorial on creating my own mobs and using the new AI. There are more than enough on creating blocks, but I had a really hard time creating my own mob.
I'm getting a bad attention-***** vibe from this thread. A tutorial thread that includes more "I'm a girl, look at me. I even have pictures to prove it" than tutorials? I'm sorry if I'm offending everyone and in case there will actually be tutorials, I'd really like to see a tutorial on creating my own mobs and using the new AI. There are more than enough on creating blocks, but I had a really hard time creating my own mob.
I'm getting more of a "I'm a great big impatient douche" vibe from this post. Patience. She did say in the OP that they may be delayed due to school.
Rollback Post to RevisionRollBack
Learn some Java before you mod, and skip over the chapter on ModLoader, straight to MinecraftForge. It's better. Trust me.
-------------Thanks---------------
To Mojang - For creating the amazing game that we all play.
To The Minecraft Forge Team (Past & Present) - For Making Forge
To drinfernoo (I think I spelled that right) - For helping in my extended absences
To Direwolf20 - For getting me into Minecraft / Minecraft Modding in the first place
--------------Addendum-----------------
1.) I am a grammar Nazi, so be forewarned
2.) Be polite please, I know I can't make you but I will ignore you, and I ask all those who aren't being rude to ignore the ones who are. Rudeness gets you nowhere.
3.) If you have a suggestion on another tutorial to add to the poll, post it below
API:
For some odd reason I got this requested a few times from people, they wanted to know how to make an API. So to make it simple because I can't really show you how to make one because really APIs are just a collection of code that may help you when making the finale product. So I'm really only going to say that, and this: if you want to make an API then come up with the idea for the API is it going to be like the dimension API or is it going to be like chicken bones's chicken core and just help your code or add universal features. Then just make the code on how you want it, without making a mod file (unless you want to sometimes its better) and whenever you want to use it just import it.
For all those who requested this and want an example or someone who wants an example then post about it or message me about it and Ill see about making an example.
Armor:
TutorialArmor.java:
TutorialArmor.java:
Your Mod File:
To Get The Rendering ID:
For Boots:
For Helmet:
For Plate:
For Leggings:
In Your Common Proxy:
Add The Following Method:
In Your Client Proxy:
Override The addArmor Method From The CommonProxy:
Dimension:
From now on btw all my tutorials are going on this site: www.minecraftforgetutorials.weebly.com
its a joint tutorial website set up by DarkHax & jcm(something comes after this I just don't remember) they asked me if I would be willing to help out, so I said yes.
They also have nice tutorials floating around the MC forums, so check them out, I will post links sometime soon to them. but here is the tutorial: http://minecraftforg...n-tutorial.html
Tools:
Coming Soon
Audio Tutorials:
In The Core @Mod() File:
Add the following method to you @PreInit Method:
Then you are going to need to make a new method in here:
In The Item / Block That Plays The Sound File:
In The onBlockActivated() Method or the onItemRightClick() Method add the following line + what ever else you have in there:
Biomes & Biome Generation:
In The Core @Mod File:
Add The Following Object Declaration To The File:
In The @Init Method Add:
Next Make A New Class That Extends BiomeGenBase Example:
And a good one at that Here's a link
There's also a really good container GUI tutorial on MinecrafForge's wiki, here
For a furnace with two (or more ) inputs, you want to make a recipe that uses a HashMap with an ItemStack[] array as its input, and a single ItemStack as an output, and just check to make sure both items in the array are present in your furnace slots. There a tutorial on a furnace with two outputs here, but I guess that's sort of backwards
I just wrote one, but while posting this, I realized it could be coded _alot_ better, so I'll maybe post the source when I'm done.
Thank you too I'd really like to see some tutorials on hooks, more details on the whole NetworkMod thing (how it works, not just c&p), and tools/armor. Another cool one would be for new mobs.
I really hope these come soon Asyncronous, It seems like all of 1.3.2 Forge tutorials I can find are for "your first block" and "your first item", which, admittedly, are a little too simple for me by now
Let me know if I can help at all
+1 On that note, I think I'll write a Forge Ore tutorial now.
Also, something I'd love to see is how to make a gui without a TileEntity, but with an item or something.
I've made a GUI which opens using keybindings, without the need of a TileEntity.
!!! Modloader !!! Let me go get my cross So, what exactly was the problem? The GUI doesn't open?
You only need a TileEntity if it's going to be a Container (chest, furnace, crafting table, etc...). You can register a TileEntity with an Item, though, if I'm not mistaken.
As far as I know, you can make a TileEntity for anything, as it's just an entity, so it doesn't have to have a block or other physical object bound to it.
I'm getting more of a "I'm a great big impatient douche" vibe from this post. Patience. She did say in the OP that they may be delayed due to school.