• 0

    posted a message on How to make armor have infinite durability?
    Perhaps it only works if you edit the base classes. If you want it to protect, set the integer array values to higher numbers.
    Posted in: Modification Development
  • 0

    posted a message on Minecraft ModLoader 1.5.1 Tutorial
    But still remove the "/Textures/".
    Posted in: Tutorials
  • 0

    posted a message on How to make armor have infinite durability?
    No, in EnumArmorMaterial, set the first integer to Double.POSITIVE_INFINITY. i.e.
    UNDEAD((int)Double.POSITIVE_INFINITY, new int[]{3, 8, 6, 3}, 9);

    That will make it invincible.
    Posted in: Modification Development
  • 0

    posted a message on Minecraft ModLoader 1.5.1 Tutorial
    I think I know the error. Change your mod's class name from Mod_moswordsandmobs to mod_moswordsandmobs.
    Posted in: Tutorials
  • 0

    posted a message on Minecraft ModLoader 1.5.1 Tutorial
    Try changing the item id from 1000 to a different, higher number.
    Posted in: Tutorials
  • 0

    posted a message on Minecraft ModLoader 1.5.1 Tutorial
    Ah. In your setUnlocalized name, remove the "/Textures/". That should fix it, as long as your texture is in minecraft.jar -> textures -> items.
    Posted in: Tutorials
  • 0

    posted a message on Minecraft ModLoader 1.5.1 Tutorial
    May I see your code?
    Posted in: Tutorials
  • 0

    posted a message on I have no clue how to fix this error, PLEASE HELP!
    addOverride is no longer a method for minecraft 1.5.1. Replace your line of code with
    [font="Verdana, Geneva, Tahoma, sans-serif"][size="2"][color="#282828"]EmeraldSword.setUnlocalizedName("swordEmerald");[/color][/size][/font]
    [font="Verdana, Geneva, Tahoma, sans-serif"][size="2"][color="#282828"]
    [/color][/size][/font]Remove all of that color crap, I don't know how that got there...
    but replace your code with
    EmeraldSword.setUnlocalizedName("swordEmerald");
    and make sure your texture is in minecraft.jar -> textures -> items
    Posted in: Modification Development
  • 0

    posted a message on Minecraft ModLoader 1.5.1 generateSurface Won't Work
    Still doesn't work. The IDE says it's correct, but the method still doesn't seem to be being called.
    Posted in: Modification Development
  • 0

    posted a message on Minecraft ModLoader 1.5.1 Tutorial
    Quote from TheCobblestone

    Hey, the methode
    .getIndirectPowerOutput();
    dosen't exists...

    It only works for blocks, i.e.
    public static Block myBlock = new Block(190, Material.glass).getIndirectPowerOutput("myBlock");
    Posted in: Tutorials
  • 0

    posted a message on [RESOLVED] Graphical/texture glitch
    What Minecraft version are you using? Also, are you using ModLoader or Forge?
    Posted in: Modification Development
  • 0

    posted a message on Minecraft ModLoader 1.5.1 generateSurface Won't Work
    I have made ores generate in the past, but it stopped working since the 1.5.1 update. Here's my code- (It's in the mod_*** class)
        public void generateSurface(World var1, Random var2, int var3, int var4)
        {
            for (int var5 = 0; var5 < 5; ++var5)
            {
                int var6 = var3 + var2.nextInt(16);
                int var7 = var2.nextInt(48);
                int var8 = var4 + var2.nextInt(16);
                (new WorldGenMinable(oreBronze.blockID, 17, Block.stone.blockID)).generate(var1, var2, var6, var7, var8);
            }
        }

    I have a BlockBronzeOre class and I've compared the methods from 1.5.1 to 1.4.7. They stayed the same, but I've noticed this method isn't even being called, even though it is in the BaseMod.class. Any help would be greatly appreciated.
    Posted in: Modification Development
  • 1

    posted a message on [SOLVED] I want to make my forge mods to notify players when there is an update
    You should get your own site for this, but you can do
    import java.io.*;
    import java.net.URL;
    
    public class UpdateChecker {
    private final static String version = "website/version.html";
    private final static String whatsNew = "website/new.html";
    
    public static String getVersion() throws Exception {
    String data = getData(version);
    return data.substring(data.indexOf("[version]") + 9, data.indexOf("[/version]"));
    }
    
    public static String getWhatsNew() throws Exception {
    String data = getData(whatsNew);
    return data.substring(data.indexOf("[new]") + 9, data.indexOf("[/new]"));
    }
    
    public static String getData(String address) throws Exception {
    URL url = new URL(address);
    
    InputStream html = null;
    html = url.openStream();
    int c = 0;
    StringBuffer buffer = new StringBuffer("");
    while (c != -1) {
    c = html.read();
    buffer.append((char)c);
    }
    return buffer.toString();
    }
    }

    Then go into EntityPlayerSP.java and put this code under the updateEntityActionState method
            double thisVer = yourVersion;
            double currentVer;
            if(x == 0) {
    try {
    currentVer = Double.parseDouble(UpdateChecker.getVersion());
           if(currentVer > thisVer) {
            this.mc.thePlayer.sendChatToPlayer("Your mods are out of date!\n Your version is " + thisVer + "! The current version is " + currentVer + "!");
            x++;
           }
           if(currentVer <= thisVer) {
            x++;
           }
    } catch (NumberFormatException e) {
    e.printStackTrace();
    } catch (Exception e) {
    e.printStackTrace();
    }
            }
    Posted in: Modification Development
  • 0

    posted a message on Adding more images for blocks / items without using forge or modloader
    It's best possible in Minecraft 1.5. You can do it without ModLoader, but you need to edit base classes. Just copy some code from Block.grass or something.
    Posted in: Modification Development
  • 0

    posted a message on addOverride doesn't work
    Here's your solution. For blocks, remove the .addOverride method. Instead, put
    .getIndirectPowerOutput("textureNameWithoutPNG");
    Put the block texture in minecraft.jar -> textures -> blocks.
    For items, remove the .addOverride method. Instead, put
    .setUnlocalizedName("textureNameWithoutPNG");
    Put the texture in minecraft.jar -> textures -> items. That will fix your problem!
    Posted in: Modification Development
  • To post a comment, please .