• 0

    posted a message on Cannot login into server. Keep Timing out
    I have already dealt with mod conflicts.
    Posted in: Server Support and Administration
  • 0

    posted a message on Cannot login into server. Keep Timing out
    I am setting up a server for me and some buds to play on with a bunch of mods. Below is the console output of the "ls" command showing what mods are installed on client and server since some mods are client side only.

    CLIENT


    SERVER


    2014-03-13 03:59:46 [INFO] [Minecraft-Server] shaqaruden joined the game
    2014-03-13 03:59:46 [INFO] [STDOUT] Loading Player: shaqaruden

    2014-03-13 03:59:46 [INFO] [STDOUT] Sending serverside check to: shaqaruden

    2014-03-13 03:59:46 [INFO] [STDOUT] [Mekanism] Sent config to 'shaqaruden.'

    2014-03-13 04:00:19 [INFO] [STDERR] java.net.SocketTimeoutException: Read timed out

    2014-03-13 04:00:19 [INFO] [STDERR] at java.net.SocketInputStream.socketRead0(Native Method)

    2014-03-13 04:00:19 [INFO] [STDERR] at java.net.SocketInputStream.read(SocketInputStream.java:152)

    2014-03-13 04:00:19 [INFO] [STDERR] at java.net.SocketInputStream.read(SocketInputStream.java:122)

    2014-03-13 04:00:19 [INFO] [STDERR] at java.io.FilterInputStream.read(FilterInputStream.java:133)

    2014-03-13 04:00:19 [INFO] [STDERR] at org.bouncycastle.crypto.io.CipherInputStream.nextChunk(Unknown Source)

    2014-03-13 04:00:19 [INFO] [STDERR] at org.bouncycastle.crypto.io.CipherInputStream.read(Unknown Source)

    2014-03-13 04:00:19 [INFO] [STDERR] at java.io.DataInputStream.readUnsignedByte(DataInputStream.java:288)

    2014-03-13 04:00:19 [INFO] [STDERR] at net.minecraft.network.packet.Packet.func_73272_a(Packet.java:145)

    2014-03-13 04:00:19 [INFO] [STDERR] at net.minecraft.network.TcpConnection.func_74447_i(TcpConnection.java:325)

    2014-03-13 04:00:19 [INFO] [STDERR] at net.minecraft.network.TcpConnection.func_74450_c(TcpConnection.java:549)

    2014-03-13 04:00:19 [INFO] [STDERR] at net.minecraft.network.TcpReaderThread.run(SourceFile:94)

    2014-03-13 04:00:19 [INFO] [STDERR] java.net.SocketException: Socket closed

    2014-03-13 04:00:19 [INFO] [STDERR] at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:121)

    2014-03-13 04:00:19 [INFO] [STDERR] at java.net.SocketOutputStream.write(SocketOutputStream.java:159)

    2014-03-13 04:00:19 [INFO] [STDERR] at org.bouncycastle.crypto.io.CipherOutputStream.write(Unknown Source)

    2014-03-13 04:00:19 [INFO] [STDERR] at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:82)

    2014-03-13 04:00:19 [INFO] [STDERR] at java.io.BufferedOutputStream.flush(BufferedOutputStream.java:140)

    2014-03-13 04:00:19 [INFO] [STDERR] at java.io.DataOutputStream.flush(DataOutputStream.java:123)

    2014-03-13 04:00:19 [INFO] [STDERR] at net.minecraft.network.TcpWriterThread.run(SourceFile:121)

    2014-03-13 04:00:19 [INFO] [Minecraft-Server] shaqaruden lost connection: disconnect.genericReason


    any idea whats going on?
    Posted in: Server Support and Administration
  • 0

    posted a message on Mekanism v9.4.0 - Industrial Turbines, Thermoelectric Boilers, Fusion Reactors!
    Im having sound issues on mac. When I enter a world my sound artifacts or something.
    Posted in: Minecraft Mods
  • 0

    posted a message on Is there a Cross-Platform Minecraft Modeller?
    Quote from Anon10W1z

    There is a modeller for Mac called MCmodeller. For Windows, use Techne, which has a very similar interface.

    P.S. Are you the youtuber Shaqaruden? You make nice tutorials!


    Only problem with MCModeller is the links do not work, they are all dead.

    Yes its me :P
    Posted in: Modification Development
  • 0

    posted a message on Is there a Cross-Platform Minecraft Modeller?
    Well title asked the question.
    Posted in: Modification Development
  • 0

    posted a message on Item Looses Durability on Crafting
    I have setup an item to test crafting recipes that it will loose durability when crafted but for some reason this can only be done once. Meaning I put the item in the crafting bench and I get the item I want and the durability does decrease but after that I can no longer craft with that item.

    Heres my code
    In my inCrafting method in my Crafting Handler
    //Crafting Dmagae Item
      for (int i = 0; i < craftMatrix.getSizeInventory(); i++) {
       if (craftMatrix.getStackInSlot(i) != null) {
        ItemStack j = craftMatrix.getStackInSlot(i);
       
        if (j.getItem() != null && j.getItem() == RedStoneMain.redstoneGem) {
    	 ItemStack k = new ItemStack(RedStoneMain.redstoneGem, 2, (j.getItemDamage() + 1));
    	
    	 if (k.getItemDamage() >= k.getMaxDamage()) {
    	  k.stackSize--;
    	 }
    	
    	 craftMatrix.setInventorySlotContents(i, k);
        }
       }
      }


    Crafting Recipe
    GameRegistry.addRecipe(new ItemStack(Item.redstone, 1), new Object[] { "T", 'T', (new ItemStack(RedStoneMain.redstoneGem,1,-1))});


    Constructor of Item taking Damage
    public ItemRedstoneGem(int par1) {
      super(par1);
      maxStackSize = 1;
      setMaxDamage(10);
    }


    The Crafting handler is being called because Im using it for other things as well.

    Am I missing something?
    Posted in: Modification Development
  • 0

    posted a message on [1.6.4] Custom Portal for Custom Dimensions
    Anyone have any ideas?
    Posted in: Modification Development
  • 0

    posted a message on [1.6.4] Custom Portal for Custom Dimensions
    anything anybody?
    Posted in: Modification Development
  • 0

    posted a message on [1.6.4] Custom Portal for Custom Dimensions
    I tried that as well and it didn't work. It's really boggling my mind :P
    Posted in: Modification Development
  • 0

    posted a message on [1.6.4] Custom Portal for Custom Dimensions
    This is my first time trying to make a custom dimension. I have a work portal and a working dimension but what I have left to do is to make the portal activator. I have created a custom fire block that will light my portal but Im getting an error in the onBlockAdded method. Here is the method,

    public void onBlockAdded(World par1World, int par2, int par3, int par4)
        {
    	    if (par1World.provider.dimensionId > 0 || par1World.getBlockId(par2, par3 - 1, par4) != RedStoneMain.redstoneGemOre.blockID || !RedStoneMain.redPortalBlock.tryToCreatePortal(par1World, par2, par3, par4))
    	    {
    		    if (!par1World.doesBlockHaveSolidTopSurface(par2, par3 - 1, par4) && !this.canNeighborBurn(par1World, par2, par3, par4))
    		    {
    			    par1World.setBlockToAir(par2, par3, par4);
    		    }
    		    else
    		    {
    			    par1World.scheduleBlockUpdate(par2, par3, par4, this.blockID, this.tickRate(par1World) + par1World.rand.nextInt(10));
    		    }
    	    }
        }


    The error I'm getting is on the reference to the tryToCreatePortal method of the redPortalBlock class. Here is the error,
    The method tryToCreatePortal(World, int, int, int) is undefined for the type Block


    Here is my redPortalBlock class code,
    package Redstone_Tutorial.block;
    import Redstone_Tutorial.RedStoneMain;
    import cpw.mods.fml.relauncher.Side;
    import cpw.mods.fml.relauncher.SideOnly;
    import java.util.Random;
    import net.minecraft.block.BlockBreakable;
    import net.minecraft.block.material.Material;
    import net.minecraft.entity.Entity;
    import net.minecraft.item.ItemMonsterPlacer;
    import net.minecraft.util.AxisAlignedBB;
    import net.minecraft.world.IBlockAccess;
    import net.minecraft.world.World;
    public class BlockRedPortal extends BlockBreakable
    {
        public BlockRedPortal(int par1)
        {
    	    super(par1, "portal", Material.portal, false);
    	    this.setTickRandomly(true);
        }
        /**
    	 * Ticks the block if it's been scheduled
    	 */
        public void updateTick(World par1World, int par2, int par3, int par4, Random par5Random)
        {
    	    super.updateTick(par1World, par2, par3, par4, par5Random);
    	    if (par1World.provider.isSurfaceWorld() && par5Random.nextInt(2000) < par1World.difficultySetting)
    	    {
    		    int l;
    		    for (l = par3; !par1World.doesBlockHaveSolidTopSurface(par2, l, par4) && l > 0; --l)
    		    {
    			    ;
    		    }
    		    if (l > 0 && !par1World.isBlockNormalCube(par2, l + 1, par4))
    		    {
    			    Entity entity = ItemMonsterPlacer.spawnCreature(par1World, 57, (double)par2 + 0.5D, (double)l + 1.1D, (double)par4 + 0.5D);
    			    if (entity != null)
    			    {
    				    entity.timeUntilPortal = entity.getPortalCooldown();
    			    }
    		    }
    	    }
        }
        /**
    	 * Returns a bounding box from the pool of bounding boxes (this means this box can change after the pool has been
    	 * cleared to be reused)
    	 */
        public AxisAlignedBB getCollisionBoundingBoxFromPool(World par1World, int par2, int par3, int par4)
        {
    	    return null;
        }
        /**
    	 * Updates the blocks bounds based on its current state. Args: world, x, y, z
    	 */
        public void setBlockBoundsBasedOnState(IBlockAccess par1IBlockAccess, int par2, int par3, int par4)
        {
    	    float f;
    	    float f1;
    	    if (par1IBlockAccess.getBlockId(par2 - 1, par3, par4) != this.blockID && par1IBlockAccess.getBlockId(par2 + 1, par3, par4) != this.blockID)
    	    {
    		    f = 0.125F;
    		    f1 = 0.5F;
    		    this.setBlockBounds(0.5F - f, 0.0F, 0.5F - f1, 0.5F + f, 1.0F, 0.5F + f1);
    	    }
    	    else
    	    {
    		    f = 0.5F;
    		    f1 = 0.125F;
    		    this.setBlockBounds(0.5F - f, 0.0F, 0.5F - f1, 0.5F + f, 1.0F, 0.5F + f1);
    	    }
        }
        /**
    	 * Is this block (a) opaque and (B) a full 1m cube?  This determines whether or not to render the shared face of two
    	 * adjacent blocks and also whether the player can attach torches, redstone wire, etc to this block.
    	 */
        public boolean isOpaqueCube()
        {
    	    return false;
        }
        /**
    	 * If this block doesn't render as an ordinary block it will return False (examples: signs, buttons, stairs, etc)
    	 */
        public boolean renderAsNormalBlock()
        {
    	    return false;
        }
        /**
    	 * Checks to see if this location is valid to create a portal and will return True if it does. Args: world, x, y, z
    	 */
        public boolean tryToCreatePortal(World par1World, int par2, int par3, int par4)
        {
    	    byte b0 = 0;
    	    byte b1 = 0;
    	    if (par1World.getBlockId(par2 - 1, par3, par4) == RedStoneMain.redstoneGemOre.blockID || par1World.getBlockId(par2 + 1, par3, par4) == RedStoneMain.redstoneGemOre.blockID)
    	    {
    		    b0 = 1;
    	    }
    	    if (par1World.getBlockId(par2, par3, par4 - 1) == RedStoneMain.redstoneGemOre.blockID || par1World.getBlockId(par2, par3, par4 + 1) == RedStoneMain.redstoneGemOre.blockID)
    	    {
    		    b1 = 1;
    	    }
    	    if (b0 == b1)
    	    {
    		    return false;
    	    }
    	    else
    	    {
    		    if (par1World.isAirBlock(par2 - b0, par3, par4 - b1))
    		    {
    			    par2 -= b0;
    			    par4 -= b1;
    		    }
    		    int l;
    		    int i1;
    		    for (l = -1; l <= 2; ++l)
    		    {
    			    for (i1 = -1; i1 <= 3; ++i1)
    			    {
    				    boolean flag = l == -1 || l == 2 || i1 == -1 || i1 == 3;
    				    if (l != -1 && l != 2 || i1 != -1 && i1 != 3)
    				    {
    					    int j1 = par1World.getBlockId(par2 + b0 * l, par3 + i1, par4 + b1 * l);
    					    boolean isAirBlock = par1World.isAirBlock(par2 + b0 * l, par3 + i1, par4 + b1 * l);
    					    if (flag)
    					    {
    						    if (j1 != RedStoneMain.redstoneGemOre.blockID)
    						    {
    							    return false;
    						    }
    					    }
    					    else if (!isAirBlock && j1 != RedStoneMain.portalSpark.blockID)
    					    {
    						    return false;
    					    }
    				    }
    			    }
    		    }
    		    for (l = 0; l < 2; ++l)
    		    {
    			    for (i1 = 0; i1 < 3; ++i1)
    			    {
    				    par1World.setBlock(par2 + b0 * l, par3 + i1, par4 + b1 * l, RedStoneMain.redPortalBlock.blockID, 0, 2);
    			    }
    		    }
    		    return true;
    	    }
        }
        /**
    	 * Lets the block know when one of its neighbor changes. Doesn't know which neighbor changed (coordinates passed are
    	 * their own) Args: x, y, z, neighbor blockID
    	 */
        public void onNeighborBlockChange(World par1World, int par2, int par3, int par4, int par5)
        {
    	    byte b0 = 0;
    	    byte b1 = 1;
    	    if (par1World.getBlockId(par2 - 1, par3, par4) == this.blockID || par1World.getBlockId(par2 + 1, par3, par4) == this.blockID)
    	    {
    		    b0 = 1;
    		    b1 = 0;
    	    }
    	    int i1;
    	    for (i1 = par3; par1World.getBlockId(par2, i1 - 1, par4) == this.blockID; --i1)
    	    {
    		    ;
    	    }
    	    if (par1World.getBlockId(par2, i1 - 1, par4) != RedStoneMain.redstoneGemOre.blockID)
    	    {
    		    par1World.setBlockToAir(par2, par3, par4);
    	    }
    	    else
    	    {
    		    int j1;
    		    for (j1 = 1; j1 < 4 && par1World.getBlockId(par2, i1 + j1, par4) == this.blockID; ++j1)
    		    {
    			    ;
    		    }
    		    if (j1 == 3 && par1World.getBlockId(par2, i1 + j1, par4) == RedStoneMain.redstoneGemOre.blockID)
    		    {
    			    boolean flag = par1World.getBlockId(par2 - 1, par3, par4) == this.blockID || par1World.getBlockId(par2 + 1, par3, par4) == this.blockID;
    			    boolean flag1 = par1World.getBlockId(par2, par3, par4 - 1) == this.blockID || par1World.getBlockId(par2, par3, par4 + 1) == this.blockID;
    			    if (flag && flag1)
    			    {
    				    par1World.setBlockToAir(par2, par3, par4);
    			    }
    			    else
    			    {
    				    if ((par1World.getBlockId(par2 + b0, par3, par4 + b1) != RedStoneMain.redstoneGemOre.blockID || par1World.getBlockId(par2 - b0, par3, par4 - b1) != this.blockID) && (par1World.getBlockId(par2 - b0, par3, par4 - b1) != RedStoneMain.redstoneGemOre.blockID || par1World.getBlockId(par2 + b0, par3, par4 + b1) != this.blockID))
    				    {
    					    par1World.setBlockToAir(par2, par3, par4);
    				    }
    			    }
    		    }
    		    else
    		    {
    			    par1World.setBlockToAir(par2, par3, par4);
    		    }
    	    }
        }
        @SideOnly(Side.CLIENT)
        /**
    	 * Returns true if the given side of this block type should be rendered, if the adjacent block is at the given
    	 * coordinates.  Args: blockAccess, x, y, z, side
    	 */
        public boolean shouldSideBeRendered(IBlockAccess par1IBlockAccess, int par2, int par3, int par4, int par5)
        {
    	    if (par1IBlockAccess.getBlockId(par2, par3, par4) == this.blockID)
    	    {
    		    return false;
    	    }
    	    else
    	    {
    		    boolean flag = par1IBlockAccess.getBlockId(par2 - 1, par3, par4) == this.blockID && par1IBlockAccess.getBlockId(par2 - 2, par3, par4) != this.blockID;
    		    boolean flag1 = par1IBlockAccess.getBlockId(par2 + 1, par3, par4) == this.blockID && par1IBlockAccess.getBlockId(par2 + 2, par3, par4) != this.blockID;
    		    boolean flag2 = par1IBlockAccess.getBlockId(par2, par3, par4 - 1) == this.blockID && par1IBlockAccess.getBlockId(par2, par3, par4 - 2) != this.blockID;
    		    boolean flag3 = par1IBlockAccess.getBlockId(par2, par3, par4 + 1) == this.blockID && par1IBlockAccess.getBlockId(par2, par3, par4 + 2) != this.blockID;
    		    boolean flag4 = flag || flag1;
    		    boolean flag5 = flag2 || flag3;
    		    return flag4 && par5 == 4 ? true : (flag4 && par5 == 5 ? true : (flag5 && par5 == 2 ? true : flag5 && par5 == 3));
    	    }
        }
        /**
    	 * Returns the quantity of items to drop on block destruction.
    	 */
        public int quantityDropped(Random par1Random)
        {
    	    return 0;
        }
        /**
    	 * Triggered whenever an entity collides with this block (enters into the block). Args: world, x, y, z, entity
    	 */
        public void onEntityCollidedWithBlock(World par1World, int par2, int par3, int par4, Entity par5Entity)
        {
    	    if (par5Entity.ridingEntity == null && par5Entity.riddenByEntity == null)
    	    {
    		    par5Entity.setInPortal();
    	    }
        }
        @SideOnly(Side.CLIENT)
        /**
    	 * Returns which pass should this block be rendered on. 0 for solids and 1 for alpha
    	 */
        public int getRenderBlockPass()
        {
    	    return 1;
        }
        @SideOnly(Side.CLIENT)
        /**
    	 * A randomly called display update to be able to add particles or other items for display
    	 */
        public void randomDisplayTick(World par1World, int par2, int par3, int par4, Random par5Random)
        {
    	    if (par5Random.nextInt(100) == 0)
    	    {
    		    par1World.playSound((double)par2 + 0.5D, (double)par3 + 0.5D, (double)par4 + 0.5D, "portal.portal", 0.5F, par5Random.nextFloat() * 0.4F + 0.8F, false);
    	    }
    	    for (int l = 0; l < 4; ++l)
    	    {
    		    double d0 = (double)((float)par2 + par5Random.nextFloat());
    		    double d1 = (double)((float)par3 + par5Random.nextFloat());
    		    double d2 = (double)((float)par4 + par5Random.nextFloat());
    		    double d3 = 0.0D;
    		    double d4 = 0.0D;
    		    double d5 = 0.0D;
    		    int i1 = par5Random.nextInt(2) * 2 - 1;
    		    d3 = ((double)par5Random.nextFloat() - 0.5D) * 0.5D;
    		    d4 = ((double)par5Random.nextFloat() - 0.5D) * 0.5D;
    		    d5 = ((double)par5Random.nextFloat() - 0.5D) * 0.5D;
    		    if (par1World.getBlockId(par2 - 1, par3, par4) != this.blockID && par1World.getBlockId(par2 + 1, par3, par4) != this.blockID)
    		    {
    			    d0 = (double)par2 + 0.5D + 0.25D * (double)i1;
    			    d3 = (double)(par5Random.nextFloat() * 2.0F * (float)i1);
    		    }
    		    else
    		    {
    			    d2 = (double)par4 + 0.5D + 0.25D * (double)i1;
    			    d5 = (double)(par5Random.nextFloat() * 2.0F * (float)i1);
    		    }
    		    par1World.spawnParticle("portal", d0, d1, d2, d3, d4, d5);
    	    }
        }
        @SideOnly(Side.CLIENT)
        /**
    	 * only called by clickMiddleMouseButton , and passed to inventory.setCurrentItem (along with isCreative)
    	 */
        public int idPicked(World par1World, int par2, int par3, int par4)
        {
    	    return 0;
        }
    }


    Any ideas on how to fix this error?
    Posted in: Modification Development
  • 0

    posted a message on Add an enchantment on crafting
    I wonder if theres a way to have it dynamic, that whenever and Tool/Weapon/Armor is combined with a enchantment Item it enchants that item with whatever that enchantment item is(speed III) for example without having to create custom items for each.
    Posted in: Modification Development
  • 0

    posted a message on [1.6.2] [Forge] Sheenrox82's Forge 1.6.2 Texturing Tutorial - Blocks and Items.
    I have a video covering different textures for different sides of blocks. Video is below, even though its for biomes I can guess the same code will apply to machines as well.


    Scrub to 13:10
    Posted in: Mapping and Modding Tutorials
  • 0

    posted a message on Custom Mob Problem
    I have created a custom mob and Im having a problem with its move speed.

    When the mob moves it only nudges along, very slowly.

    Model
    package Redstone_Tutorial.model;
    import net.minecraft.client.model.ModelBase;
    import net.minecraft.client.model.ModelBiped;
    import net.minecraft.client.model.ModelRenderer;
    import net.minecraft.client.resources.ResourceLocation;
    import net.minecraft.entity.Entity;
    import net.minecraft.util.MathHelper;
    public class ReddyFreddy extends ModelBiped
    {
      //fields
        ModelRenderer Body;
        ModelRenderer Right_Leg;
        ModelRenderer Left_Leg;
        ModelRenderer Head;
        ModelRenderer Right_Arm;
        ModelRenderer Left_Arm;
     
      public ReddyFreddy()
      {
        textureWidth = 128;
        textureHeight = 64;
       
    	  Body = new ModelRenderer(this, 88, 25);
    	  Body.addBox(0F, 0F, 0F, 12, 24, 8);
    	  Body.setRotationPoint(-6F, -10F, 0F);
    	  Body.setTextureSize(128, 64);
    	  Body.mirror = true;
    	  setRotation(Body, 0F, 0F, 0F);
    	  Right_Leg = new ModelRenderer(this, 0, 49);
    	  Right_Leg.addBox(-2.5F, 0F, -2.5F, 5, 10, 5);
    	  Right_Leg.setRotationPoint(-2.5F, 14F, 4F);
    	  Right_Leg.setTextureSize(128, 64);
    	  Right_Leg.mirror = true;
    	  setRotation(Right_Leg, 0F, 0F, 0F);
    	  Left_Leg = new ModelRenderer(this, 25, 49);
    	  Left_Leg.addBox(-2.5F, 0F, -2.5F, 5, 10, 5);
    	  Left_Leg.setRotationPoint(3F, 14F, 4F);
    	  Left_Leg.setTextureSize(128, 64);
    	  Left_Leg.mirror = true;
    	  setRotation(Left_Leg, 0F, 0F, 0F);
    	  Head = new ModelRenderer(this, 88, 0);
    	  Head.addBox(-5F, -10F, -4F, 10, 10, 10);
    	  Head.setRotationPoint(0F, -10F, 1F);
    	  Head.setTextureSize(128, 64);
    	  Head.mirror = true;
    	  setRotation(Head, 0F, 0F, 0F);
    	  Right_Arm = new ModelRenderer(this, 0, 0);
    	  Right_Arm.addBox(-14F, -2.5F, -2.5F, 14, 5, 5);
    	  Right_Arm.setRotationPoint(-6F, -6F, 4F);
    	  Right_Arm.setTextureSize(128, 64);
    	  Right_Arm.mirror = true;
    	  setRotation(Right_Arm, 0F, 0F, 0F);
    	  Left_Arm = new ModelRenderer(this, 0, 13);
    	  Left_Arm.addBox(0F, -2.5F, -2.5F, 14, 5, 5);
    	  Left_Arm.setRotationPoint(6F, -6F, 4F);
    	  Left_Arm.setTextureSize(128, 64);
    	  Left_Arm.mirror = true;
    	  setRotation(Left_Arm, 0F, 0F, 0F);
      }
     
      public void render(Entity par1Entity, float par2, float par3, float par4, float par5, float par6, float par7)
      {
        setRotationAngles(par2, par3, par4, par5, par6, par7, par1Entity);
        Body.render(par7);
        Right_Leg.render(par7);
        Left_Leg.render(par7);
        Head.render(par7);
        Right_Arm.render(par7);
        Left_Arm.render(par7);
      }
     
      private void setRotation(ModelRenderer model, float x, float y, float z)
      {
        model.rotateAngleX = x;
        model.rotateAngleY = y;
        model.rotateAngleZ = z;
      }
     
      public void setRotationAngles(float par1, float par2, float par3, float par4, float par5, float par6, Entity par7Entity)
      {
       super.setRotationAngles(par1, par2, par3, par4, par5, par6, par7Entity);
      
       this.Head.rotateAngleY = par4 / (180F / (float)Math.PI);
       this.Head.rotateAngleX = par5 / (170F / (float)Math.PI);
      
       this.Left_Leg.rotateAngleX = MathHelper.cos(par1 * 0.6662F) *  2.0F * par2 * 0.5F;
       this.Left_Leg.rotateAngleY = 0.0F;
      
       this.Right_Leg.rotateAngleX = MathHelper.cos(par1 * 0.6662F + (float)Math.PI) *  1.4F * par2;
       this.Right_Leg.rotateAngleY = 0.0F;
      
       this.Right_Arm.rotateAngleZ = MathHelper.cos(par1 * 0.6662F + (float)Math.PI) * 2.0F * par2 * 0.5F;
       this.Right_Arm.rotateAngleY = 0.0F;
      
       this.Left_Arm.rotateAngleZ = MathHelper.cos(par1 * 0.6662F) * 2.0F * par2 * 0.5F;
       this.Left_Arm.rotateAngleY = 0.0F;
      }
    }



    Entity
    package Redstone_Tutorial.entity;
    import Redstone_Tutorial.RedStoneMain;
    import net.minecraft.client.resources.ResourceLocation;
    import net.minecraft.entity.EnumCreatureAttribute;
    import net.minecraft.entity.ai.EntityAIAttackOnCollide;
    import net.minecraft.entity.ai.EntityAIHurtByTarget;
    import net.minecraft.entity.ai.EntityAINearestAttackableTarget;
    import net.minecraft.entity.ai.EntityAIWander;
    import net.minecraft.entity.ai.EntityAIWatchClosest;
    import net.minecraft.entity.monster.EntityMob;
    import net.minecraft.entity.player.EntityPlayer;
    import net.minecraft.item.Item;
    import net.minecraft.world.World;
    public class EntityReddyFreddy extends EntityMob {
    public EntityReddyFreddy(World par1World) {
      super(par1World);
      this.getNavigator().setSpeed(0.3F);
      this.experienceValue = 10;
      this.tasks.addTask(5, new EntityAIWander(this, 1.0D));
    	    this.tasks.addTask(6, new EntityAIWatchClosest(this, EntityPlayer.class, 6.0F));
    	    this.tasks.addTask(2, new EntityAIAttackOnCollide(this, EntityPlayer.class, 1.0D, false));
    	    this.tasks.addTask(7, new EntityAIWatchClosest(this, EntityPlayer.class, 8.0F));
    	    this.targetTasks.addTask(1, new EntityAIHurtByTarget(this, true));
    	    this.targetTasks.addTask(2, new EntityAINearestAttackableTarget(this, EntityPlayer.class, 0, true));
    }
    
    protected boolean isAIEnabled()
        {
    	    return true;
        }
    
    public int getMaxHealth()
        {
      return 20;
        }
    
    protected String getHurtSound()
        {
    	    return "mob.zombie.hurt";
        }
        protected String getDeathSound()
        {
    	    return "mob.zombie.death";
        }
       
        protected void playStepSound(int par1, int par2, int par3, int par4)
        {
    	    this.playSound("mob.zombie.step", 0.15F, 1.0F);
        }
       
        protected int getDropItemId()
        {
    	    return Item.rottenFlesh.itemID;
        }
       
        public EnumCreatureAttribute getCreatureAttribute()
        {
    	    return EnumCreatureAttribute.UNDEAD;
        }
        protected void dropRareDrop(int par1)
        {
    	    switch (this.rand.nextInt(3))
    	    {
    		    case 0:
    			    this.dropItem(RedStoneMain.redstoneGem.itemID, 1);
    			    break;
    	    }
        }
       
        public void onLivingUpdate() {
    	 super.onLivingUpdate();
        }
    
    }


    Render
    package Redstone_Tutorial.render;
    import Redstone_Tutorial.entity.EntityReddyFreddy;
    import Redstone_Tutorial.model.ReddyFreddy;
    import net.minecraft.client.model.ModelBase;
    import net.minecraft.client.renderer.entity.RenderLiving;
    import net.minecraft.client.resources.ResourceLocation;
    import net.minecraft.entity.Entity;
    import net.minecraft.entity.EntityLiving;
    public class RenderReddyFreddy extends RenderLiving  {
    protected ReddyFreddy model;
    
    public RenderReddyFreddy(ModelBase par1ModelBase, float par2) {
      super(par1ModelBase, par2);
      model = ((ReddyFreddy)mainModel);
    }
    
    public void renderReddyFreddy(EntityReddyFreddy entity, double par2, double par4, double par6, float par8, float par9) {
      super.doRenderLiving(entity, par2, par4, par6, par8, par9);
    }
    
    public void doRenderLiving(EntityLiving par1EntityLiving, double par2, double par4, double par6, float par8, float par9) {
      renderReddyFreddy((EntityReddyFreddy)par1EntityLiving, par2, par4, par6, par8, par9);
    }
    
    public void doRender(Entity par1Entity, double par2, double par4, double par6, float par8, float par9) {
      renderReddyFreddy((EntityReddyFreddy)par1Entity, par2, par4, par6, par8, par9);
    }
    @Override
    protected ResourceLocation func_110775_a(Entity entity) {
      return new ResourceLocation("redstonetutorial:textures/mobs/ReddyFreddy.png");
    }
    
    }


    Any Ideas?Could it be the length of the legs?
    Posted in: Modification Development
  • 0

    posted a message on [1.6.2]Texture Not Working for Custom Mob
    Figured it all out, FINALLY
    Posted in: Modification Development
  • 0

    posted a message on [1.6.2]Texture Not Working for Custom Mob
    I am creating a test custom mob and I have it spawn via an egg and I can hear the sounds but its completely invisible. I have my texture located at "assets/redstonetutorial/textures/mob/ReddyFreddy.png"

    Here is my render class
    package Redstone_Tutorial.render;
    import Redstone_Tutorial.entity.EntityReddyFreddy;
    import Redstone_Tutorial.model.ReddyFreddy;
    import net.minecraft.client.model.ModelBase;
    import net.minecraft.client.renderer.entity.RenderLiving;
    import net.minecraft.client.resources.ResourceLocation;
    import net.minecraft.entity.Entity;
    import net.minecraft.entity.EntityLiving;
    public class RenderReddyFreddy extends RenderLiving  {
    public RenderReddyFreddy(ModelBase par1ModelBase, float par2) {
      super(par1ModelBase, par2);
      model = ((ReddyFreddy)mainModel);
    }
    
    @Override
    protected ResourceLocation func_110775_a(Entity entity) {
      return null;
    }
    
    protected ReddyFreddy model;
    public void renderReddyFreddy(EntityReddyFreddy entity, double par2, double par4, double par6, float par8, float par9) {
      super.doRenderLiving(entity, par2, par4, par6, par8, par9);
    }
    
    public void doRenderLiving(EntityLiving par1EntityLiving, double par2, double par4, double par6, float par8, float par9) {
      renderReddyFreddy((EntityReddyFreddy)par1EntityLiving, par2, par4, par6, par8, par9);
    }
    
    public void doRender(Entity par1Entity, double par2, double par4, double par6, float par8, float par9) {
      renderReddyFreddy((EntityReddyFreddy)par1Entity, par2, par4, par6, par8, par9);
    }
    
    private static final ResourceLocation field_110830_f = new ResourceLocation("redstonetutorial:/textures/mob/ReddyFreddy.png");
    private static final ResourceLocation field_110833_a = new ResourceLocation("redstonetutorial:/textures/mob/ReddyFreddy.png");
    
    }


    My Entity Class
    package Redstone_Tutorial.entity;
    import Redstone_Tutorial.RedStoneMain;
    import net.minecraft.client.resources.ResourceLocation;
    import net.minecraft.entity.EnumCreatureAttribute;
    import net.minecraft.entity.monster.EntityMob;
    import net.minecraft.item.Item;
    import net.minecraft.world.World;
    public class EntityReddyFreddy extends EntityMob {
    public EntityReddyFreddy(World par1World) {
      super(par1World);
      this.moveForward = 0.50F;
      this.moveStrafing = 0.25F;
      this.experienceValue = 10;
    }
    
    public int getMaxHealth()
        {
      return 20;
        }
    
    protected String getLivingSound()
        {
    	    return "mob.zombie.say";
        }
    
    protected String getHurtSound()
        {
    	    return "mob.zombie.hurt";
        }
        protected String getDeathSound()
        {
    	    return "mob.zombie.death";
        }
       
        protected void playStepSound(int par1, int par2, int par3, int par4)
        {
    	    this.playSound("mob.zombie.step", 0.15F, 1.0F);
        }
       
        protected int getDropItemId()
        {
    	    return Item.rottenFlesh.itemID;
        }
       
        public EnumCreatureAttribute getCreatureAttribute()
        {
    	    return EnumCreatureAttribute.UNDEAD;
        }
        protected void dropRareDrop(int par1)
        {
    	    switch (this.rand.nextInt(3))
    	    {
    		    case 0:
    			    this.dropItem(RedStoneMain.redstoneGem.itemID, 1);
    			    break;
    	    }
        }
    
    }


    My Model Code
    package Redstone_Tutorial.model;
    import net.minecraft.client.model.ModelBase;
    import net.minecraft.client.model.ModelBiped;
    import net.minecraft.client.model.ModelRenderer;
    import net.minecraft.client.resources.ResourceLocation;
    import net.minecraft.entity.Entity;
    public class ReddyFreddy extends ModelBiped
    {
      //fields
        ModelRenderer Body;
        ModelRenderer Right_Leg;
        ModelRenderer Left_Leg;
        ModelRenderer Head;
        ModelRenderer Right_Arm;
        ModelRenderer Left_Arm;
     
      public ReddyFreddy()
      {
        textureWidth = 128;
        textureHeight = 64;
       
    	  Body = new ModelRenderer(this, 88, 25);
    	  Body.addBox(0F, 0F, 0F, 12, 24, 8);
    	  Body.setRotationPoint(-6F, -10F, 0F);
    	  Body.setTextureSize(128, 64);
    	  Body.mirror = true;
    	  setRotation(Body, 0F, 0F, 0F);
    	  Right_Leg = new ModelRenderer(this, 0, 49);
    	  Right_Leg.addBox(-2.5F, 0F, -2.5F, 5, 10, 5);
    	  Right_Leg.setRotationPoint(-2.5F, 14F, 4F);
    	  Right_Leg.setTextureSize(128, 64);
    	  Right_Leg.mirror = true;
    	  setRotation(Right_Leg, 0F, 0F, 0F);
    	  Left_Leg = new ModelRenderer(this, 25, 49);
    	  Left_Leg.addBox(-2.5F, 0F, -2.5F, 5, 10, 5);
    	  Left_Leg.setRotationPoint(3F, 14F, 4F);
    	  Left_Leg.setTextureSize(128, 64);
    	  Left_Leg.mirror = true;
    	  setRotation(Left_Leg, 0F, 0F, 0F);
    	  Head = new ModelRenderer(this, 88, 0);
    	  Head.addBox(-5F, -10F, -4F, 10, 10, 10);
    	  Head.setRotationPoint(0F, -10F, 1F);
    	  Head.setTextureSize(128, 64);
    	  Head.mirror = true;
    	  setRotation(Head, 0F, 0F, 0F);
    	  Right_Arm = new ModelRenderer(this, 0, 0);
    	  Right_Arm.addBox(-14F, -2.5F, -2.5F, 14, 5, 5);
    	  Right_Arm.setRotationPoint(-6F, -6F, 4F);
    	  Right_Arm.setTextureSize(128, 64);
    	  Right_Arm.mirror = true;
    	  setRotation(Right_Arm, 0F, 0F, 0F);
    	  Left_Arm = new ModelRenderer(this, 0, 13);
    	  Left_Arm.addBox(0F, -2.5F, -2.5F, 14, 5, 5);
    	  Left_Arm.setRotationPoint(6F, -6F, 4F);
    	  Left_Arm.setTextureSize(128, 64);
    	  Left_Arm.mirror = true;
    	  setRotation(Left_Arm, 0F, 0F, 0F);
      }
     
      public void render(Entity par1Entity, float par2, float par3, float par4, float par5, float par6, float par7)
      {
        setRotationAngles(par2, par3, par4, par5, par6, par7, par1Entity);
        Body.render(par7);
        Right_Leg.render(par7);
        Left_Leg.render(par7);
        Head.render(par7);
        Right_Arm.render(par7);
        Left_Arm.render(par7);
      }
     
      private void setRotation(ModelRenderer model, float x, float y, float z)
      {
        model.rotateAngleX = x;
        model.rotateAngleY = y;
        model.rotateAngleZ = z;
      }
     
      public void setRotationAngles(float par1, float par2, float par3, float par4, float par5, float par6, Entity par7Entity)
      {
      
      }
    }


    Any Ideas?
    Posted in: Modification Development
  • To post a comment, please .