Minecraft Blogs / Tutorial

How to mod for minecraft 1.7.2/1.7.10

  • 915 views, 1 today
  • 2
  • 0
  • 5
hoganas187's Avatar hoganas187
Level 27 : Expert Dragon
3
Hello pmc members, today im gonna show you how to mod for minecraft 1.7.2/1.7.10, its gonna be text tutorial, im gonna upload only 2 parts at pmc other parts will gonna be at roliks community forum



Lets Setup a proxy for your minecraft mod

1.First create instance of your mod

Spoiler - click to reveal
@Instance(MODID)
public static yourmodid instance;
note!: it has to be a bit lower then your modid & version

2.create a client proxy for your mod
Spoiler - click to reveal
package yourpackage.proxy;






import net.minecraft.init.Blocks;
import net.minecraft.init.Items;
import cpw.mods.fml.client.registry.RenderingRegistry;






public class ClientProxy extends CommonProxy {

public void registerRenderThings() {

//EntityTiles






}

}
3.Create a another proxy that will be commonproxy it will render everything in multiplayer! so your mod will work in mp!
Spoiler - click to reveal
package yourpackage.proxy;




import cpw.mods.fml.common.registry.GameRegistry;

public class CommonProxy {


public void registerRenderThings() {

}







}
4.add this to your mainclass 
Spoiler - click to reveal
Proxy.registerRenderThings();
so it will render, mobs,armor and etc!


5.and final step add this to your main class
Spoiler - click to reveal
 @SidedProxy(clientSide = "yourmainclass.proxy.ClientProxy", serverSide = "yourmainclass.proxy.CommonProxy" )
public static CommonProxy Proxy;

And now you have arleady finished setting up your proxy & now it will work for both singleplayer & multiplayer!



Now lets create a basic item!
 

1.simply finish texture and make assets folder & item folder


2.Start making item by registering it in code!
Spoiler - click to reveal
public static Item TutorialItem;

3.Import some stuff, so it wouldn't show you errors!
Spoiler - click to reveal
import net.minecraft.init.Items;
import net.minecraft.item.Item;

4.Lets go further by making item work in game!
Spoiler - click to reveal
TutorialItem = new TutorialItem().setUnlocalizedName("TutorialItem");
GameRegistry.registerItem(TutorialItem, "TutorialItem");

5.Hover over error that will show in new TutorialItem() & create a class named TutorialItem

Spoiler - click to reveal
package yourpackage.items;


import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.item.Item;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;

public class TutorialItem extends Item {

public TutorialItem() {
this.setCreativeTab(creativetabs.misc);
}




@SideOnly(Side.CLIENT)
public void registerIcons(IIconRegister iconRegister) {
this.itemIcon = iconRegister.registerIcon(yourmodid.MODID + ":" + this.getUnlocalizedName().substring(5));
}




}

and now youre done how to setup langueage file & more tutorials will be uploaded at roliks community forum, check them out there!

bye :) good luck in further mod developing!
CreditRoliks Community
Tags

Create an account or sign in to comment.

1
02/29/2020 1:47 am
Level 1 : New Miner
spiders and lizards lover
spiders and lizards lover's Avatar
well i know a bit of coding i am working on a mod right now this will help
1
01/11/2015 4:47 pm
Level 6 : Apprentice Architect
Seevin
Seevin's Avatar
Theres programs that do alot of this for you -_-
2
01/11/2018 2:30 am
Level 78 : Legendary Senpai
Soulas
Soulas's Avatar
Well programs suck actually, best way is to code things by your self :) as you can make many of awesome things and even make normal cows or pigs explode, make super powerfull armor that gives you buffs, make giant godzilla beasts and much more :)
1
01/12/2015 5:22 pm
Level 8 : Apprentice Network
PeterJHC
PeterJHC's Avatar
…such as?
1
01/11/2015 4:48 pm
Level 27 : Expert Dragon
hoganas187
hoganas187's Avatar
and so, but java is best thing to create mods with :)
Planet Minecraft

Website

© 2010 - 2024
www.planetminecraft.com

Welcome