Introduction
The reason I write these tutorials is because others asked me to. I release the source code to all my mods, and although it's very lightly commented and minimalistic, it's probably better to look at that than to read this and suffer the frustration induced by my inability to explain things properly. On the off chance that any of this helps you out, be sure to click

Before you begin make sure you have:
- MCP up and running.
- A sound understanding of Java (you should be at a stage where you only think about how to implement something and not how to code it).
- Familiarity with the Minecraft source code.
- Experience with modding simple to intermediate mods.
- The patience to deal with these tutorials.
Contents
TextureFX and Animated Textures (Simple)
TextureFX and Animated Textures(Advanced)
GUIs, HUDs and OpenGL
Advanced Entity/NPC AI
Smooth State-Based Model Animation
Custom Block Rendering and Redstone
TextureFX and Animated Textures (Simple)
Under Construction...
(because there's a simpler way than below if you don't want to do anything fancy)
TextureFX and Animated Textures (Advanced)
This tutorial aims to show how to code custom block animations, similar to water, lava and portal animations, like for example in this mod. You might need to know a tiny little bit of colour theory.
First of all let’s start with a basic framework of how subclasses of TextureFX.class are laid out. If you take a look at TextureWaterFX, TextureLavaFX or any of the others, it'll make little sense with the amount of obfuscated code. So let’s start with TextureFX.class:
package net.minecraft.src; import org.lwjgl.opengl.GL11; public class TextureFX { public TextureFX(int i) { imageData = new byte[1024 /*GL_FRONT_LEFT*/]; anaglyphEnabled = false; textureId = 0; tileSize = 1; tileImage = 0; iconIndex = I; } public void onTick() { } public void bindImage(RenderEngine renderengine) { if(tileImage == 0) GL11.glBindTexture(3553 /*GL_TEXTURE_2D*/, renderengine.getTexture("/terrain.png")); else if(tileImage == 1) GL11.glBindTexture(3553 /*GL_TEXTURE_2D*/, renderengine.getTexture("/gui/items.png")); } public byte imageData[]; public int iconIndex; public boolean anaglyphEnabled; public int textureId; public int tileSize; public int tileImage; }
The byte array “imageData” is the most important field in this class. You’ll notice its 1024 bytes long, meaning it can take a 1024 byte image; the same size a normal 16*16 texture would be. There are 255 pixels , every pixel is a 4 byte, or 32-bit, colour. And in the 4 bytes of information every pixel has, one is the Red value, one is the Green value, one is the Blue value and one is the Alpha (transparency) value. This is why in HTML you can define colours with a hex number; every two digits in that number represent a colour in RGB.
Understanding that isn’t very important. What’s important is that whatever image is in that byte array will be the image displayed on our block. We can ignore pretty much everything else for now except two things.
The first is the field “iconIndex”. Whatever this field is set as in the constructor, will be the the texture our TextureFX replaces. If I were to set TextureLavaFX’s iconIndex field to the iconIndex of sand, every sand block in my world would look like lava for instance (more on that later).
The second not so import field is “anaglyphEnabled”, the field that tells you if Notch’s little 3D thing is on or not but we won’t need to worry about that for now.
So how would you create your own animations? There are several ways. Of course you could manipulate individual bytes, create fancy noise generators or use sine and cosine waves the same way Notch did for his animations but I chose to do it a bit more controlled.
Introducing the ImageIO.read(URL input) method. It saves a lot of work and works on many image file formats. When given a URL this method will return a BufferedImage object with which you can iterate through individual pixels for RGB values.
So say you have an image in a folder called “textures” within the package you’re working in, this is how you would load an image into a 1024 byte long byte array:
private byte bg[] = new byte[1024]; public TextureSomethingFX() { super(myIconIndex); try { loadBG(ImageIO.read(this.getClass().getResource("textures/background.png"))); } catch (IOException e) { e.printStackTrace(); } } private void loadBG(BufferedImage bi) { for (int row=0;row<16;row++) for (int col=0;col<16;col++) { int pixel = bi.getRGB(col, row); bg [((col+(row*16))*4)+0] = (byte)((pixel>>16)&0xFF); //Red bg[((col+(row*16))*4)+1] = (byte)((pixel>>8)&0xFF); //Green bg [((col+(row*16))*4)+2] = (byte)((pixel)&0xFF); //Blue bg [((col+(row*16))*4)+3] = (byte)((pixel>>24)&0xFF); //Alpha } }
Read it through slowly; it’ll make sense. I don’t know if going into any more detail would be insulting your intelligence, dear reader, but if I should elaborate on this leave a reply. Byte manipulation ftw.
So what is this bg? Why don’t I load it directly into imageData? What is the “myIconIndex” I hear you ask? Let’s take this one by one.
You might have noticed the “onTick()” method in TextureFX. This is used for changing the info imageData holds over time so that it animates. We copied “background.png” int a separate byte array so that it remains unchanged and we can use it in this method when need be.
Remember when we said that imageData is 16*16*4 (1024) bytes large? We can load any number of images into byte arrays of any size and use them later on imageData. This means you could load several 16*16 images and loop through them in onTick(), like a gif, but let’s do something a little fancier.
Let’s load a 2*4 image of a red rectangle (it would make more sense to just iterate through the byte array and set all red values for every pixel to FF or all ones effectively making everything red) and move that around on our background image. The onTick method would look something like this:
private int tickCounter=0, posX= 0, posY=0; public void onTick() { if(tickCounter%2==0) { //BG to bottom layer. imageData = bg.clone(); //This has to be a clone so we don’t screw up the clean copy of the image we loaded. //Draw red rectangle. for (int row=2+posY,texY=0;row<6+posY;row++,texY++) //It will be drawn on rows 2 to 5. texY is the row in the image (we want all). for (int col=0+posX,texX=0;col<2+posX;col++,texX++) { if (anaglyphEnabled); //3D thing, cba //ARGB Layers. imageData[((col+(row*16))*4)+0] = rect[((texX+(texY *2))*4)+0]; //Red imageData[((col+(row*16))*4)+1] = rect[((texX+(texY *2))*4)+1]; //Green imageData[((col+(row*16))*4)+2] = rect[((texX+(texY*2))*4)+2]; //Blue imageData[((col+(row*16))*4)+3] = rect[((texX+(texY*2))*4)+3]; //Alpha } //Move red rectangle. posX++; posY++; posX = posX>14?0:posX; posY = posY>14?0:posY; //^That is to make sure it doesn’t run off the image. //Better code would be to check before setting imageData if a pixel is off the array. } tickCounter++; if(tickCounter>100) tickCounter=0; }
If you’re wondering what tickCounter is, you can use it to aid your animations. If you wanted to you could simulate a sine wave with every tick being a certain degree, or as I’ve done here, slow down an animation so that it only updates on every second tick (ticCounter%2==0 is only true for even numbers).
If none of that made sense you should check out the source code in this mod (included in the download). The animation isn’t as stupid as here so you’ll see where the code is coming from. If all else fails, stick to making something gif-like:
private int frame=0; public void onTick() { switch (frame) { case 0: imageData = frame1; break; case 1: imageData = frame2; break; case 2: imageData = frame3; break; case 3: imageData = frame4; break; default: break; } }
Where individual frames are loaded the same way we loaded “background.png”. You could also use a tick counter to slow down the animation or the Random library to make it animate on chance.
Finally, all you need to do is use get an iconIndex and register your TextureFX, preferably using ModLoader to prevent incompatibilities. The easiest way to get an icon index is as follows. You know how normally you’d set “blockIndexInTexture” (or multiple ints for a block with different faces) to:
ModLoader.addOverride("/terrain.png", "/textures/background.png");
This time just use:
ModLoader.getUniqueSpriteIndex("/terrain.png");
You'll most likely set a block's "blockIndexInTexture" field to it and then set iconIndex in your TextureFX's constructor to that. Then, in your “mod_Something” class, override the method:
public void RegisterAnimation(Minecraft game) { ModLoader.addAnimation(new TextureSomethingFX()); }
Using your TextureFX class. And that’s it! You now have a block with an animated texture(s)! :smile.gif:
GUIs, HUDs and OpenGL
This tutorial will cover how to create:
- GUIs that contain item slots.
- Dynamic HUDs.
- Custom buttons/sliders (not just the default minecraft buttons that can easily be created using GuiAPI or ModOptionsAPI)
- As well as how render anything on screen, ever.
Once again, most of what I'm about to explain is best understood if you read the source to my mods that have GUIs/HUDS.
Before we begin with the things that involve OpenGL, let's look at how to make a simple GUI with item slots, like crafting, furnaces, chests etc. Theses can be opened when interacting with a block, entity or even just pressing a key.
To create such a GUI, you'll need main 4 classes. For consistency, let's name them based on the MCP conventions:
- InventoryExample
- GuiExample
- ContainerExample
- SlotExample
To explain this better, I'll be using the code from my lawn mower mod. Full source code in the download. The only difference between creating a GUI for an entity as opposed to a block is the use of TileEntities for blocks in order to save the slot contents to the world save file. More on that later.
Now let's go through these classes. InventoryExample is the class that's instantiated for every Entity/TileEntity. It extends nothing and implements the IInventory interface that includes self-explanatory methods:
package net.minecraft.src; public interface IInventory { public abstract int getSizeInventory(); public abstract ItemStack getStackInSlot(int i); public abstract ItemStack decrStackSize(int i, int j); public abstract void setInventorySlotContents(int i, ItemStack itemstack); public abstract String getInvName(); public abstract int getInventoryStackLimit(); public abstract void onInventoryChanged(); public abstract boolean canInteractWith(EntityPlayer entityplayer); }
The InventoryExample class should contain a single (or possibly several) ItemStack array, capable of accommodating the ItemStacks in every slot. For InventoryLawnMower, I decide I want 5 new slots and thus used the array
public ItemStack cargo[] = new ItemStack[5];
to store the contents. That's all there is to it. Everything else should make sense. I decide to copy some methods from InventoryPlayer, such as "addItemStackToInventory(ItemStack itemstack)" and the methods it calls, to make changing the inventory array (in this case "cargo") without the player being involved (e.g. with block collisions), safer as opposed to setting individual elements and doing a million checks. Normally, if the player is the only one that can change the slots, you wouldn't need to bother. Even if said Entity/Block is destroyed, you'd empty the inventory in their onDeath()/onBlockRemoval() methods.
What's important to note is that this is the same array that gets written to NBT so that the next time you log on the stuff is still there. The way I do it for the lawn mower mod is as follows:
public NBTTagList writeToNBT(NBTTagList nbttaglist) { for (int i = 0; i < cargo.length; i++) if (cargo[i] != null) { NBTTagCompound nbttagcompound = new NBTTagCompound(); nbttagcompound.setByte("Slot", (byte) i); cargo[i].writeToNBT(nbttagcompound); nbttaglist.setTag(nbttagcompound); } return nbttaglist; } public void readFromNBT(NBTTagList nbttaglist) { cargo = new ItemStack[5]; for (int i = 0; i < nbttaglist.tagCount(); i++) { NBTTagCompound nbttagcompound = (NBTTagCompound) nbttaglist.tagAt(i); int j = nbttagcompound.getByte("Slot") & 0xff; ItemStack itemstack = new ItemStack(nbttagcompound); if (itemstack.getItem() == null) continue; if (j >= 0 && j < cargo.length) cargo[j] = itemstack; } onInventoryChanged(); }
I'm assuming anyone reading these tutorials understands the NBT system but if not, post a reply.
Basically, when writing to NBT, we create an NBTTagCompounds while iterating through the inventory's ItemStack array to add to the NBTTagList and pass them through to the individual ItemStacks. The code for that is already there, if you check ItemStack.class, and it writes the ID, stack size and damage to the compound. On reading the same data from NBT, we initialise the array to what we read from NBT, the same way but reversed. The code should make sense.
Of course if it's a simple inventory, for a block only, you can use metadata instead if the information you need to store can be expressed in 4 bits or less (for example if the jukebox had a GUI. 0000 or 0 is nothing, 0001 or 1 is the gold music disc and 0010 or 2 is the green music disc. Normal inventory information can't be stored as a number 16 or less).
The rest is comparatively simple. GuiSomething is a class that extends GuiContainer which is in turn a child of GuiScreen. In Minecraft.class, there's a field called "currentScreen"; whatever's on your screen is as a result of this being set to an instance of GuiScreen. Most of the code is already done in the abstract class GuiContainer. If you look at GuiLawnMower I barely override anything:
package net.minecraft.src.lawnMower.gui; import net.minecraft.src.*; import org.lwjgl.opengl.GL11; public class GuiLawnMower extends GuiContainer { public GuiLawnMower(InventoryLawnMower cargo, InventoryPlayer playerInv) { super(new ContainerLawnMower(cargo, playerInv)); } protected void drawGuiContainerForegroundLayer() { fontRenderer.drawString("Fuel", 10, 10, 0x005939); fontRenderer.drawString("Cargo", 100, 10, 0x005939); fontRenderer.drawString("Inventory", 8, 72, 0x005939); } protected void drawGuiContainerBackgroundLayer(float f) { mc.renderEngine.bindTexture(mc.renderEngine.getTexture("/lawnMower/textures/lawnmowergui.png")); GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F); drawTexturedModalRect((width-xSize)/2, (height-ySize)/2, 0, 0, xSize, ySize); } public void onGuiClosed() { super.onGuiClosed(); inventorySlots.getSlot(0).onSlotChanged(); } }
There's a tiny bit of OpenGL already, but assuming you're creating a GUI based on the 256*256 one already in minecraft, the code will stay exactly the same.
Wherever you have an instance of FontRenderer you can drawString or drawStringWithShadow anywhere on screen. In this case the first parameter is the string, the second and third are the x and y positions respectively relative to the background, so the top left corner is 0,0 and it gets greater as you move away from it (all in pixels). The last parameter is a colour expressed in hexadecimal. The rest should make sense and if it doesn't it's either irrelevant or will be covered later (OpenGL stuff).
There are other methods in GuiContainer that may come in handy to override for slightly more complex things including:
- mouseClicked(int x, int y, int button) : void
- mouseMovedOrUp(int x, int y, int button) : void
- keyTyped(char key, int keyCode) : void
- doesGuiPauseGame() : boolean
Mouse buttons go from 0 to 2 and key codes can be found here.
Now you'll notice in the constructor we create a new instance of ContainerLawnMower. This class is also relatively simple. All it does is create the slots for the inventory, setting their locations and IDs, in order to make sure the GUI highlights them on mouseover and check if they've been clicked when the mouse is. The code is self-explanatory:
package net.minecraft.src.lawnMower.gui; import net.minecraft.src.*; public class ContainerLawnMower extends Container { public ContainerLawnMower(InventoryLawnMower cargo, InventoryPlayer playerInv) { addSlot(new SlotLawnMower(cargo, 0, 30, 35)); for (int row=0; row<2; row++) for (int col=0; col<2; col++) addSlot(new SlotLawnMower(cargo, 1+row+(col*2), 102+col*18, 26+row*18)); for(int i = 0; i < 3; i++) for(int k = 0; k < 9; k++) addSlot(new Slot(playerInv, k + i * 9 + 9, 8 + k * 18, 84 + i * 18)); for(int j = 0; j < 9; j++) addSlot(new Slot(playerInv, j, 8 + j * 18, 142)); } @Override public boolean isUsableByPlayer(EntityPlayer player) { return true; } }
"isUsableByPlayer(EntityPlayer player)" is an abstract class in Container and must be included. One would imagine you'd only make it return true if the player is a certain distance away from the thing the GUI is bound to, but since this check is already done for the right-click method (i.e. you can only right click it if you're close enough) it would be redundant to do it here.
In the constructor I add my five special Slots (they're all SlotLawnMower because they have special characteristics; more on that later). Once again if you read it through it should make sense. The parameters are the inventory, the id, and x and y positions relative to the top left of the GUI (in pixels). The last two for loops add the player's inventory slots to the GUI so they can exchange items between the two inventories, cargo and playerInv, like with any other normal GUI. The reason the last 9 slots are in a separate for loop is because they are offset by a few pixels (these are the slots you can scroll through in-game).
Finally, we get to the Slot classes. If you wanted just a simple inventory slot that accepts any item with a default global inventory stack limit, usually 64, you could simply instantiate a new "Slot" object and you'd be done. But what if you wanted a selective slot? Once again I'll use SlotLawnMower as an example:
package net.minecraft.src.lawnMower.gui; import net.minecraft.src.*; class SlotLawnMower extends Slot { private int slotIndex; SlotLawnMower(IInventory iinventory, int slotIndex, int posX, int posY) { super(iinventory, slotIndex, posX, posY); this.slotIndex = slotIndex; } @Override public int getSlotStackLimit() { return slotIndex==0?1:64; //This isn't in the actual mod; just an example. } @Override public boolean isItemValid(ItemStack itemstack) { if (slotIndex == 0 && itemstack.itemID == Item.coal.shiftedIndex) return true; if (slotIndex > 0 && itemstack.itemID == Item.seeds.shiftedIndex) return true; return false; } }
If need be you could even override "onPickupFromSlot(ItemStack itemstack)" and do something fancy. Once again though the code says it all. The method "isItemValid(ItemStack itemstack)" is called when the player tries to put something in the slot and if it returns false they can't (e.g. food in armour slots). The same goes for stack size limits although this isn't used as much since the limit is often already set for the item, like tools. Alternatively I could have made a separate slot class for slot 0 (the fuel slot) and one for the others (cargo slots), but I reckon this is tidier.
Phew! Now that all of that is done and fitting textures are drawn, how do you make it appear? Easy! Call this static method when you want it to appear:
ModLoader.OpenGUI(player, new GuiLawnMower(cargo, player.inventory));
where player is an instance of EntityPlayer and cargo is you inventory (you've seen the constructor). Chances are you'll want to call it in an Entity's "interact(EntityPlayer player) : boolean" method (you should have the inventory field in the entity class as mentioned earlier) or in a block's "blockActivated(World world, int x, int y, int z, EntityPlayer player) : boolean" method (you'd use the coords to access the TileEntitiy and then pass it to the GUI so you know which inventory you're accessing. Just check BlockFurnace or something; if you want me to explain tile entities, reply).
Everything is done automatically (e.g. the GUI closes when you press E or Esc (unless you messed with the keyTyped method mentioned earlier in which case you know what you're doing)) and you don't have to worry about the background stuff. Also please only do it with the ModLoader method. Anything else would just be stupid.
And there you have it: A very simple slot GUI! (Now take a break and read the rest later).
Before we continue with HUDs, buttons and other fancy things, let's take a quick look at the relevant OpenGL methods (included in lwjgl that minecraft uses) in a nutshell. The next bit is pretty much copied straight from a post I made aaages ago. I'll elaborate, edit and maybe talk a bit about Tessellator.class eventually:
Here's the method (with which you draw things on screen) in English:
drawTexturedModalRect(posX, posY, texX, texY, sizeX, sizeY);
Where
posX = X postion on screen in pixels.
posY = Y postion on screen in pixels.
You've gotta be careful with these since the player could be using a different screen resolution or resize the Minecraft window. I recommend you precede this with:
ScaledResolution scaledresolution = new ScaledResolution( game.gameSettings, game.displayWidth, game.displayHeight); width = scaledresolution.getScaledWidth(); height = scaledresolution.getScaledHeight(); //This is the middle of the screen relative to the size of the screen. posX = (width-sizeX)/2; posY = (height-sizeY)/2;
texX = X postion of the texture in an image file in pixels.
texY = Y postion of the texture in an image file in pixels.
Once again you need to be careful; the default image size is 256*256 and changing it is troublesome.
sizeX = size of the texture relative to texX (NOT the resolution).
sizeY = size of the texture relative to texY (NOT the resolution).
What I mean by "not the resolution" is that it will draw that number of pixels starting at texX and texY and it does not affect the actual size of the image on screen.
Typically drawing something on screen looks like this:
GL11.glEnable(3042 /*GL_BLEND*/); //This turns transparency on if your image has any. GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F); //This is redundant if all 1.0F but changes the shade. GL11.glBindTexture(3553, game.renderEngine.getTexture("/PKMods/Skills/skillgui.png")); //Bind the texture to be used. game.ingameGUI.drawTexturedModalRect(posX, posY, texX, texY, sizeX, sizeY); //Draw the part you want from the sprite map. GL11.glDisable(3042 /*GL_BLEND*/); //Turn off transparency for subsequent rendering
A word on "glColor4f(...)": it may seem like you don't need it, but you do since something else could have messed with the RGBA values and screw up your image if you don't set everything to 1. The parameters are the opacity of the Red, Green, Blue and Alpha (transparency) channels respectively. For example, setting the fourth parameter to 0.5F would make the image half transparent (onto the transparency it already has from the png).
A couple of other useful GL11 methods:
GL11.glDisable(2896 /*GL_LIGHTING*/); //Stops other things drawn on screen from changing shades when your image is drawn. //This is particulartly important for drawing items (like in inventories). GL11.glDisable(2929 /*GL_DEPTH_TEST*/); //Makes your image get draw on the top layer instead of being covered by other things. //Do your stuff here. //Always end with: GL11.glEnable(2896 /*GL_LIGHTING*/); GL11.glEnable(2929 /*GL_DEPTH_TEST*/); //So you don't screw up any subsequent rendering.
Other useful methods:
RenderHelper.enableStandardItemLighting(); //A static method that stops items drawn on screen from greying out when your image is drawn. //Always end with: RenderHelper.disableStandardItemLighting();
And
game.fontRenderer.drawString("Hello World!", posX, posY, 0xFFFFFF); //or game.fontRenderer.drawStringWithShadow("Hello World!", posX, posY, 0xFFFFFF);
Where "game" is the Minecraft instance and 0xFFFFFF could be any hexadecimal colour. In this case 0xFFFFFF is white.
There are a few more really useful ones you might have even seen around but we won't be needing them for now.
The rest of this tutorial is to be continued...
Advanced Entity/NPC AI
Under Construction...
Smooth State-Based Model Animation
Under Construction...
Custom Block Rendering and Redstone
Under Construction...
15
Good News
Spaces has taken over making the mod. The mod is now located at http://www.minecraftforum.net/topic/1060102-11-dragon-craft-z-wip/.
Sadly as Server is not being downloaded much:
Server Discontinued unless you guys vote to save it.
Mod Updated!
Long over do but it is finally here. v1.0 will be next and have some Ki stuff and hopefully models for Shenron. 6 Wishes are available with Shenron Currently. In the next version Shenron will be more of an entity. as of now you can exploit the fact the Shenron block doesn't despawn.
Recipes to be up soon.
Downloads! Requires ModLoader
Risugami's ModLoader
Mod v0.4.1[1.1]Download Link
Upcoming:
After i finish version 4.0 and the bugtesting, i start work on the collaboration with
http://www.minecraft...1#entry10519146 Made by Steve_ftw.
Also I will start to let people do bug testing on new versions. (ki hint hint)
Block and armor photos are up. Recipe pictures are not as a need to get a few pics i missed. 1/13/12: gonna change the hilt recipe to something else and see if i can fix it. Gui is fixed up thanks to ziliss. I will update to 1.0 and then 1.1 when mcp is. i will do the same for v1.0.
Also as you maybe have noticed i now am the thread owner. Thanks for the hard work uber.
It requires modloader.
Current version shifted to old versions because v4.0 is out im thinking 1/14/12.
New content soon
ALL SUGGESTIONS WILL GET A PERSONAL RESPONSE
Please Contribute to the wiki.
Dragon Craft Z wiki
Upcoming:New Player classes: Saiyin, Super Saiyin(its own class), Namekian, Human Engineer/martial artist, Buu
Add new pics, reduction of block ID's and Item ID's(sprite wise), more wishes, and more mobs
Change Log:
v0.4.1--Removed Test recipe
v0.4--replaced shenron item with block.
v0.3.10--Bug fixes
SMP v0.2.3--Bug fixes
v0.3.9--Major bug fixes
-Shenron wishes fixed
SMP v0.2.2--Katchin fixed
-Bug fixes
SMP v0.2.1--bug fixes
v0.3.8-- Dragon Ball color problem fixed
-Dragon Balls no longer spawn, they apear in chests in dungeons
-Blood sword can block now
-Blood sword damage fix
-Some new textures
SMP v0.2--major bug fixes
v0.3.7--minor changes
-bug fixs
SMP v0.1--created
v0.3.6--Ragedirt speed fixed
-Namekstone added
-Namekhouse added
v0.3.5--more bug fixes
-added katchin
-Item and block ID's changed so that it is more compatible with other mods
v0.3.4--Rage dirt light re added
-Minor bug fixes
-Rage dirt bug fixes
v0.3.3--Minor bug fixes
-Dragon ball color fixed
-Blood sword crafting recipe fixed
v0.3.2--Minor bug fixes
-Switched back to mediafire
-Prep work for major update
v0.3.1--Updated to 1.8.1
-Major bug fixes
-updated features like weapons and armor(blood set)
v0.3-- Updated to 1.7.3
-minor bug fixes
v0.2--fixed dragonballs spawn code
-blood ore is now less common
-added the blood ore sword
-added full blood ore armor; its made using blood crystals witht normal recipes
-currently 4 wishes= take iron, gold, or diamond and put the material in the shape of a chestplate and add a shenron in the open spot
-4th wish is for the janemba sword, im trying to see who figs out first, hint: ull need 2 blood ore objects
-to clarify the blood sword recipe is the blade over hilt then a blood crystal
-code has been streamlined and compadibility have been increased thanks to freefortaking (freefortalking to kill)
-ragedirt doesnt currently spawn but the recipe is in, coal int the middle of the top then coal left then dirt then coal on the right, then a redstone int the middle of the bottom
-sword blades are made by taking 3 blood crystals. buting them in a line in the middle and putting iron ingots around the edges
-hopefully didnt need to add but sword hilt is made by taking blood crystal and iron and putting them in a hilt shape where the blood crystals made up the handle part
-blood when smelted gives two blood chunks, fill a 3x3 with blood chunks to get a blood crystal
-also ragedirt is slippery so its quite fun to slide around if anyone wants to make a video feel free just please post the link.
v0.1-Dragon Balls added
-Wish system with 4-5 wishes added
-Rage Dirt added(my signature block)
-OUT OF TESTING!
A Dragon Ball. Collect 7 of these and put them in an H shape to make a Shenron Block.
The Shenron Block in its current state. In V1.0 a litteral shenron will spawn from this block. Until then the Block will just have a gui.
RageDirt. Has a slippery effect when walked on and has a slight glow to it.
Blood Ore. This ore is smelted to get Blood Ore Chunks and the Chunks are put together to make Blood Crystals to make Blood ore Armor. Tools are likely in either v4.0 or version 1.0.
Image for Both NamekStone and NamekHouse. A slight texture change will be added to the namek house so you can tell them apart.
The Actual Namek House. Made of NamekStone and has 2 furnaces, 2 double chests and a crafting table. More sizes of the house will come later and hopefully some other (capsule) things. House Model From Slymask3- Maker of InstantHouse.
Katchin. Industructable, Very Explosive resistant. It also falls like sand. Known to crash servers in earlier versions. Untested with the 1.8.1 version.
Katchin is fun to work with.
Me wearing a full set of Blood Armor, which has the durability of diamond currently as mojang broke custom armors in 1.0. Normally is stronger.
The Blood Sword. Kills in two hits and is extremely durable. It is able to block like a normal sword.
Janemba's Sword. One Hit kill currently, It currently has no special power (other than blocking) But Its power is likely to be found soon.
Recipes:
Videos:
The connection was bad near the end, made it sound so funny at some parts
Because Cth asked(and has been doing most of the work so far) -uber
Old Versions: B1.8.1 versions and below require modloader and modloadermp
1.8.1 version
SMP server version 1.8.1
1.7.3 version
1.6.6 version
1.5_01 version
Signatures:
Special Thanks To:
-Nex Carnifex (this is a response to his mod request)
-ubermanclaw
-Burningating
-Gohan
-Eum3
-Nick354
-Crysune
-TheFlyGuy06
-cth977
-Bigguy11757
-killthenrun1
-FreeForTaking
-Nexusrightsi
-Paraknight
-bigguy
-flashyink
Thanks to Ziliss for helping me fix up the gui to use.
Modding Team
-UberMan, Founder, Owner
-Cth977, Lead Coder, Thread Maintainer
-killthenrun1, Coder, Video creator, PR
-bigguy11757, Texturer
-Mr_PixelatedCoder, Shenron BackGround Pic
-Flashyink, Models when they are done
-Spaces, Soon to be Coder
-Looking for More
CopyRight
This document is Copyright ?(2011) of UberManclaw(hereafter referred to as "The Owner") and is the intellectual property of The Owner. Only Minecraftforum.net and mcmodcenter.net is able to host any of The Owner's material without the consent of The Owner. It may not be placed on any other web site or otherwise distributed publicly without advance written permission. (Electronic mail is acceptable as long as you wait for a response.) If you mirror this mod page or anything The Owner has made on any other site, The Owner may seek damages through a lawsuit.
3
Updated to 1.0!
All Adfly or adcraft links are not mine but the links of the Mod Creator.
Knowing How to find and mod your minecraft jar.
Credit to Risugami for the Tutorial.
Installation
Windows:
1) Open up %appdata%, if you don't know how to do this, start>run, then type in %appdata%
2) Browse to .minecraft/bin
3) Open up minecraft.jar with WinRAR or 7zip.
4) Drag and drop the necessary files into the jar.
5) Delete the META-INF folder in the jar.
6) Run Minecraft, enjoy!
Macintosh:
1) Go to Applications>Utilities and open terminal.
2) Type in the following, line by line:
cd ~
mkdir mctmp
cd mctmp
jar xf ~/Library/Application\ Support/minecraft/bin/minecraft.jar
3) Outside of terminal, copy all the files and folders into the mctmp directory.
4) Back inside terminal, type in the following:
rm META-INF/MOJANG_C.*
jar uf ~/Library/Application\ Support/minecraft/bin/minecraft.jar ./
cd ..
rm -rf mctmp
5) Run Minecraft, enjoy!
Key: Abbreviation = Full Name
ML = ModLoader
MLMP = ModLoaderMP
MF = Minecraft Forge
AM = AudioMod
GuiApi= Gui Api
Playapi= Player Api
Base Mods:
Audio Mod: http://www.minecraftforum.net/topic/75440-v18119p5-risugamis-mods-everything-updated-prerelease-included/
{Allows Custom Sounds}
Gui Api: http://www.minecraftforum.net/topic/612536-18-guiapi-an-advanced-gui-toolkit/
{Gui stuff}
ModLoader: http://www.minecraftforum.net/topic/75440-v18119p5-risugamis-mods-everything-updated-prerelease-included/
{Base for all mods}
ModLoaderMP: http://www.minecraftforum.net/topic/182918-181-19pre5smp-flans-mods-planes-ww2-guns-vehicles-playerapi-moods-mputils-teams/#MLM
{Base for server mods}
Minecraft Forge: http://www.minecraftforum.net/topic/514000-api-minecraft-forge/
{Allows an extreme reduction in sprites used, and many other features.}
Turbo Model Thingy: http://www.minecraftforum.net/topic/182918-181-19pre5smp-flans-mods-planes-ww2-guns-vehicles-playerapi-moods-mputils-teams/#TMT
{Allows Custom Models/Textures}
Player Api: http://www.minecraftforum.net/topic/738498-100api-player-api/
{Api for compatibility for mods that change the player.}
Assisting mods:
SPC(Single Player Commands): http://www.minecraftforum.net/topic/94310-19pre5-181-single-player-commands-v213/
{Allows you to do several things. Very popular is the flying. Full list of features are on its page.}
TMI(Too Many Items): http://www.minecraftforum.net/topic/140684-100-toomanyitems-in-game-invedit-nov-19/
{Allows you to give yourself most items in the game}
Pages of mods:
Flan's Mods:
http://www.minecraftforum.net/topic/182918-181-19pre5smp-flans-mods-planes-ww2-guns-vehicles-playerapi-moods-mputils-teams/#MLM
{Planes mod, ModLoaderMp, Teams, Turbo Model Thingy, ect....}
Havvy's Mods:
http://www.minecraftforum.net/topic/625467-181-havvys-mods/page__hl__havvy's
{Self Building Pyramid, Craftable Clay, Mobs Drop Torches, Mob Kill Stats, Debugging Tool.}
iPixeli's Mods:
http://www.minecraftforum.net/topic/553793-index-ipixelis-index-collection/
{First person hand removal, Gender Mod, and a Plugin}
Risugami's Mods:
http://www.minecraftforum.net/topic/75440-v18119p5-risugamis-mods-everything-updated-prerelease-included/
{ModLoader, AudioMod, Recipe book, ect....}
Shockah's Mods: ML, MF
http://www.minecraftforum.net/topic/78064-181-shockahs-mods-updating-in-progress-sapi-r10/
{Sadly only the Api is currently updated but the Api is amazing.}
TehKrush's Mods:
http://www.minecraftforum.net/topic/119361-181-tehkrushs-mods-timber-and-hiddendoors/
{Hidden Doors, Timber!, The rest have yet to be updated.}
Individual Mods:
_303's Grappling Hook: ML, GuiApi
http://dl.dropbox.com/u/11953124/Minecraft/GrapplingHook/GrapplingHook-1.8.1v1.zip
Info:
"GrapplingHook
Minecraft Beta 1.8.1 Singleplayer
A deliciously imbalanced multi-purpose device for moving around quickly. Climbing rope, grapplinghook, gravity gun, all in one.
Requirements:
Risugami's ModLoader
Lahwran's GUI API
New: Multiple grapples at once: Each grapple you craft is unique, with separate modes remembered when you reload. You can have multiple hooks in the world, though you can only pull on one at a time. Hooks have a colored number rendered over them to distinguish them, which is also displayed in the lower left screen corner (can be disabled in options screen). Uses: Keep multiple mobs on leash; quickly switch between two points to grapple to by taking another grapple in hand; keep a grapple as a safety rope while targetting the next point with another. This features uses the new extended item data code that came with maps.
Thanks _303!
BetterThanWolves (BTW): ML, MF
http://www.minecraftforum.net/topic/253365-181-better-than-wolves-mod-v320-upd-nov-10/
{adds anchors, ropes, platforms, square wolves, block placing despensers, cauldrons(for cooking), donuts, hard boiled eggs, ect.....}
BuildCraft (BC): ML, MF, MLMP
http://www.minecraftforum.net/topic/682920-181-buildcraft-225-pipes-quarry-auto-crafting-building-engines/
{Adds pipes, machines, oil, pumps, autominers, ect....}
Coros's Mods: ML
http://www.minecraftforum.net/topic/81715-1918-coros-mods-tornadoes-particle-man-zombiecraft-map-editor-zombie-awareness-pets-nm-mode-moveplus-smooth-rain/
{Corosus brings us his wonderful mods. Better Zombies, ZombieCraft, Tornados, ect....}
Cojomax99's Mods: ML
http://www.minecraftforum.net/topic/663527-181cojomax99s-mods-includes-digital-led-analog-mountable-clocks-lapi-and-tropicraft/
{Digital Clocks, Mountable clocks, Liquid API, Tropic Craft}
Classic Light: ML
http://www.minecraftforum.net/topic/300926-19pre5-classiclight-updated-to-use-risus-19-pre5-ml/
{Works to return light to its orginal form.}
Dragon Craft Z: ML, MLMP
http://www.minecraftforum.net/topic/336104-wip181dragon-craft-zv0310-smp-v023/
{Is Working to bring the Dragon Ball Z universe to minecraft.}
EquivalentExchange (EE): ML, Forge, MLMP, AM
http://www.minecraftforum.net/topic/364525-181-equivalent-exchange-v546/
{Advanced Alchemy, Transmutation, Dark Mater, and oh about a thousand other things.}
ExtendCraft (FreeForTaking's): ML
http://www.minecraftforum.net/topic/332951-181extendcraft-v11-now-with-platinum/
{Adds many more types of metals, Colored glass, And nether ores.}
First Person Hand Removal:
http://www.minecraftforum.net/topic/643705-181-remove-first-person-hand/
{Hides the hand you see to the right}
Humans+: ML, AM, Mr_okushama's okutils. ( http://ad.cx/fthr4b )
http://www.minecraftforum.net/topic/96903-19pre518-humans-v23-now-open-to-suggestions/
{Adds several types of humans into your world}
iPixeli's Female Gender Option Mod: ML, AM
http://bitly.com/GenderMod
{Allows you to choose to be a woman instead of a man. Sounds Reflect this. 'This Multiplayer mod has the option to turn the player into a female while maintaining the minecraft style. You can choose which model you want females to be seen as.' Thanks iPixeli!.}
IndustrialCraft² (IC): ML, MLMP, MF, Client-sided MLMP-Fix, Crashing HotFix
http://www.minecraftforum.net/topic/604928-181-industrialcraft²-v115/
{Brings industry into minecraft, Too many things to list.}
Kodaichi's Clay Soldier Mod: ML
http://www.minecraftforum.net/topic/495553-181-kodas-clay-soldier-mod-v36/
{Allows you to have little clay soldiers running around that you can have battle each other.}
Little Blocks mod
http://www.minecraftforum.net/topic/730795-18-little-blocks-mod-14-now-with-redstone/
{This mod allows you to build using little blocks, on a block space. This is good especially for decor and redstone. But it looks like your going to need Recipe Book.}
Millénaire: ML
http://www.minecraftforum.net/topic/227822-181-millenaire-npc-village-192-tweaks-fixes/
{Adds Villages into your lonely world}
Optifine: ML
http://www.minecraftforum.net/topic/249637-181-optifine-hd-d2-fps-boost-hd-textures/
{Allows you to get more out of minecraft. has single core, and multicore versions.}
Original Pistons Mod:
http://www.minecraftforum.net/topic/228373-181-pistons-patch-updated/
{Allows you to make pistons like they were before being included}
pchan3's Mods: ML,
http://www.minecraftforum.net/topic/164940-181pchan3s-mods-airship-sky-pirates-steamboat/, See http://www.steam-craft.com/ for more info and Downloads.
{AirShips, SkyPirates, and SteamBoats}
RailCraft: ML, MLMP, MF
http://www.minecraftforum.net/topic/701990-181-railcraft-152-forge-smp/
{Adds several new types of rails to minecraft. It also fixes minecarts a bit.}
ScienceCraft: ML
http://www.minecraftforum.net/topic/784355-181-sciencecraft-v02-wip/page__p__10174178__fromsearch__1#entry10174178
{Brings Science into Minecraft}
Smart Moving: ML, Playapi
http://www.minecraftforum.net/topic/361430-181smp-smart-moving/
{Allows Smarter Movement}
Tropic Craft: ML
http://www.minecraftforum.net/topic/533512-181-tropicraft-v24coming-soon-tropical-realm/
{Adding tropical elelments to minecraft}
The Halloween Mod (by Kodaichi): ML, AM
http://www.minecraftforum.net/topic/751492-181-the-halloween-mod-by-kodaichi/
{adds candy, jumpkins, Halloween creepers, zombie hands, and more!}
Water Shader Mod
http://www.minecraftforum.net/topic/542215-181-water-shader-alpha-v4d/
{Gives how water looks an overhaul. It makes water look much better.}
Zombe's ModPack: ML
http://www.minecraftforum.net/topic/91055-v100-zombes-modpack-26-mods-v56-upd-19nov/
{Adds several Commands and abilitys}
Banner:
Support the new One Stop Mod Shop!
This Seems to be a good list to start with. If you want your mod added or think another should be, pm me or leave a comment.
1
Also http://mcmodding.4umer.com/t40-creating-mods-block-manipulation should clear up your render confusion.
1
not all people know how to make the skin be on a mob. and besides, players count as a creature. its based on a human and we are mammals. humans count as an animal and so does the player.
3
you will need to have mcp set up and decompiled. src means source and is the folder in your mcp jar called src. mcp set up tut for windows. I recorded my own and will do a video series to start with.
ModFiles
This tut will cover setting up a modfile to be used. You will need modloader for this coding.
Step 1 make your file. You do so by making a new text file and naming it somewhere along the lines on mod_thename. whether it matters between mod_ or Mod_ i don't think has any effect but i use the lowercase version and it seems to work fine. you need to change the .txt at the end to .java so that eclipse or net beans or what ever editor you use can open it. i recomend eclipse as it has some autocomplete things and allows running minecraft without having to recompile and open the test client.
Step 2 open it and enter your starter code
you replace the mod_thenames and "mod name" with the name of your mod. the name you set for the public class has to match the name of the file or it will Not work. java is case sensitive and it throws errors on any kind of issue like that.
okay now for basic explanations of things.
This line covers where the file is. it tells it to look in the main part of your src file in mcp. most likely trying
Will cause it to get files in the source from a folder called newfolder.
This covers the class name. public makes it usable and class makes it a class file. mod_thename is well the name. the extends means it uses the file as a base file. BaseMod is linked to modloader, which allows you to use modloader's functions in your mod file. Modloader's file is labeled as ModLoader.java
This allows you to add things in the file. this is the section know as the constructor, it can be used for modloader things, and is where you put the modloader code. both the public class and this part have to match spelling and all or it will not allow the class file to work.
This is a basic function that is required by all mod files. the
Tells the compiler that this overrides the base file. don't worry about it. its mostly a bug catcher from what i see.
This basically sets the name of the mod-file, you can put pretty much anything here.
Basic ModLoader Uses
most of these start with ModLoader. this means it uses fuctions and things from modloader.
I would like to say that you can put as many of these in a modfile as you want. there is only a limit on sprites for like texture and ids for the item or block. Never is making multiple mod_ files better. it means there are more files and they are just a pain and also it takes so much longer to update when you have multiple.
Use the property tables on my site at http://cth977.com/Modding Tutorials.html
1
delete the double slashes in front of the package. it is now usable to sub for stuff.
code like this is what you use. then you replace the id on the actual item with that.
just do this for all of them and your set. if the file isnt in your mcp go to risugami's forum page look at the modloader downloads and go the the decompile fixes, it's in that file. Happy Modding!