Jump to content

Modding, Or: How I learned to stop sucking by reading the fucking sticky.


deathrat

Recommended Posts

I picked up a book about java programming at the book store the other day. I've been reading through it lately and I'm enjoying it alot. My question is, will this help me understand how to make mods or am I just wasting my time? Keep in mind that this book doesnt have any sections with game development.

Link to comment
Share on other sites

Most of modding for minecraft is taking advantage of the structures already in place. The important bit is to be able to read code and to understand the methods provided. Aside from learning java (which is an important step), you'll want to look into the modloader javadoc and what documentation there is available for forge. There are also some tutorials available. Check the OP in this thread for links.

Link to comment
Share on other sites

  • 2 weeks later...

Something I learned last night. If you end up having to reinstall your java SDK because of a type error on recompile, it's best to just redo your decompile fresh.

Once you replace your java SDK it changes the MD5 sums, so if it bothers to recompile correctly it will assume every class has changed and needs to be sent out during reobfuscation. And you'll be picking through every aah, aaf, aha, ect... class minecraft has looking for your client files. The server portion won't even bother recompiling.

Link to comment
Share on other sites

  • 4 weeks later...
  • 1 month later...
  • 3 months later...

I am trying to make a simple mod to add blocks to my server. I just want them to be like stone with no special properties. Also I want them in the creative inventory.

I've actually managed this in 1.3.2 with forge, but I am not sure how to scale it back to 1.2.5. I have pieced together some code from the suggested tutorials, but I am not sure if I am going in the right direction.

Could someone please help me with this.


My mod file code:

package net.minecraft.src;

import net.minecraft.src.forge;

import net.minecraft.src.forge.NetworkMod;

 

public class Mod_VoyagerBlocks extends NetworkMod

{

public Mod_VoyagerBlocks() {}

 

@Override

public boolean clientSideRequired()

{

return true;

}

@Override

public boolean serverSideRequired()

{

return false;

}

 

@Override

public String getVersion() {

// TODO Auto-generated method stub

return null;

}

 

@Override

public void load() {

// TODO Auto-generated method stub

 

}

public static Block BlockHolodeck;

public static Block BlockBrownPanel;

public static Block BlockCheckerTile;

static

{

BlockHolodeck = new BlockHolodeck(3000, 0).setBlockName("Holodeck").setHardness(1.0F).setResistance(1.0F);

BlockBrownPanel = new BlockBrownPanel(3001, 0).setBlockName("Brown Panel").setHardness(1.0F).setResistance(1.0F);

BlockCheckerTile = new BlockCheckerTile(3002, 0).setBlockName("Checkerd Tile").setHardness(1.0F).setResistance(1.0F);

}

}



.

and next one of the Block class files



package net.minecraft.src;

 

import net.minecraft.src.forge.ITextureProvider;

 

public class BlockHolodeck extends Block

implements ITextureProvider

{

public BlockHolodeck(int itemID, int texture)

{

super(itemID, texture, Material.rock);

}

@Override

protected int damageDropped(int metadata)

{

return metadata;

}

@Override

public String getTextureFile()

{

return "/Voyager.Holodeck.png";

}

 

}

Link to comment
Share on other sites

This is probably a good place to ask this, so I'll ask here and hope it actually is.

Does anyone know of a good modding tutorial for 1.4.2? Preferably text based. Using a mix-and-match method from googling it like I've been doing probably isn't the best way forward when trying to learn how to mod Minecraft, and I'd rather use one which covers a lot of possibilities while actually being clear to understand than spend ages trying to find separate tutorials for different things.

Link to comment
Share on other sites

This is probably a good place to ask this, so I'll ask here and hope it actually is.

Does anyone know of a good modding tutorial for 1.4.2? Preferably text based. Using a mix-and-match method from googling it like I've been doing probably isn't the best way forward when trying to learn how to mod Minecraft, and I'd rather use one which covers a lot of possibilities while actually being clear to understand than spend ages trying to find separate tutorials for different things.

click on the advanced modding tutorials. He is updating those.

Link to comment
Share on other sites

click on the advanced modding tutorials. He is updating those.

I'll have another look, but I thought those were videos? I prefer Text tutorials for some reason, probably because I like to go at my own speed and have copy+paste available to compare.

EDIT: Another question, so I'll shove it here for you people to help with.

A lot of the tutorials have more ModLoader tutorials than Forge tutorials. Is this because these parts work the same in Forge, or are tutorial makers just preferring to make tutorials on Modloader than Forge?

Link to comment
Share on other sites

  • 6 months later...
  • 6 months later...

If a tutorial, like some of those suggested in the op, is a couple years old, will it still help me? And as far as using Forge goes, when the installer comes up do I want to install Forge client or do I want to extract the files?

Most core concepts have stayed the same (class structure, making blocks do things), but the very start of a mod has changed so dramatically between 1.2 and 1.6 that if you tried making a mod from an old guide and tried to fix the errors you'd never make it work.

At this point it's best to just use those guides as an example of what to look for in an updated guide. Probably a good idea to check the latest comments in the threads for users posting updated information, like links to new guides.

Or just check here: http://www.minecraftforge.net/wiki/Tutorials

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...