• 0

    posted a message on Custom Armor Model

    Just get instanceof the armorstand and rotate the head appropriately. It isn't too hard I think you can do it. If you don't know how msg back.

    Posted in: Modification Development
  • 0

    posted a message on Custom Armor Model

    Oh herro dere, get rid of this:

    	    else
    	    {
    	    	GL11.glPushMatrix();
    	        GL11.glScalef(1.0F, 1.0F, 1.0F);
    	        GL11.glPopMatrix();
    	        this.bipedHead.render(scale);
    	        this.bipedBody.render(scale);
    	        this.bipedRightArm.render(scale);
    	        this.bipedLeftArm.render(scale);
    	        this.bipedRightLeg.render(scale);
    	    }
    Posted in: Modification Development
  • 0

    posted a message on Custom Armor Model

    Don't worry about it. :P Glad I could help! Now if everything is working you may want to consider adding a solved or resolved tag.

    Posted in: Modification Development
  • 0

    posted a message on Custom Armor Model

    Omg, I'm a clutz forgot to pass the render through *DERP*. Here anyways change this:

    		if(this.model1 == null)
    		{
    			this.model1 = new ModelJayGarrick2(0.1F);
    		}
    		if(type == 3)
    		{
    			this.model = this.model1;
    		}
    		else
    		{
    			this.model = new ModelJayGarrick2(0);
    		}
    		if(this.model2 == null)
    		{
    			this.model2 = new ModelJayGarrick2(1.0F);
    		}


    To this:

     if(this.model2 == null){
     this.model2 = new ModelJayGarrick2(1.0F);
     }
     if(this.model1 == null)
     {
     this.model1 = new ModelJayGarrick2(0.5F);
     }
     if(type == 3)
     {
     this.model = this.model1;
     } else {
     this.model = new ModelJayGarrick2(0);
     }
     if(type == 1){
     this.model = this.model2;
     }
     }

    EDIT: I just tested this, so I can confirm this works!

    Posted in: Modification Development
  • 0

    posted a message on Custom Armor Model

    I see. Interesting... Try adding this:

    ModelBiped model2 = null;

    Then this in your getArmorModel:

    		if(this.model2 == null){
    			this.model2 = new ModelJayGarrick2(1.0F);
    		}


    Then in your ModelJayGarrick2 change this:

    		this.bipedBody.cubeList.clear();
    		this.bipedLeftArm.cubeList.clear();
    		this.bipedRightArm.cubeList.clear();
    		this.bipedLeftLeg.cubeList.clear();
    		this.bipedRightLeg.cubeList.clear();
    		this.bipedBody.addChild(this.body);
    		this.bipedLeftArm.addChild(this.leftarm);
    		this.bipedRightArm.addChild(this.rightarm);
    		if(f < 0.1){
    			this.bipedLeftLeg.addChild(this.leftleg);
    			this.bipedRightLeg.addChild(this.rightleg);
    		} else {
    			this.bipedLeftLeg.addChild(this.leftfoot);
    			this.bipedRightLeg.addChild(this.rightfoot);
    		}

    to this:

    		this.bipedBody.cubeList.clear();
    		this.bipedLeftArm.cubeList.clear();
    		this.bipedRightArm.cubeList.clear();
    		this.bipedLeftLeg.cubeList.clear();
    		this.bipedRightLeg.cubeList.clear();
    		this.bipedLeftArm.addChild(this.leftarm);
    		this.bipedRightArm.addChild(this.rightarm);
    		if(f < 0.1){
    			this.bipedLeftLeg.addChild(this.leftleg);
    			this.bipedRightLeg.addChild(this.rightleg);
    		} else {
    			this.bipedLeftLeg.addChild(this.leftfoot);
    			this.bipedRightLeg.addChild(this.rightfoot);
    		}
    		if(f == 1){
    			this.bipedBody.addChild(this.body);
    		}
    Posted in: Modification Development
  • 0

    posted a message on Custom Armor Model

    This part:

    	this.modelJayGarrick2.isSneak = entityLiving.isSneaking();
            this.modelJayGarrick2.isRiding = entityLiving.isRiding();
            this.modelJayGarrick2.isChild = entityLiving.isChild();
            this.modelJayGarrick2.aimedBow = false;
            this.modelJayGarrick2.heldItemRight = entityLiving.getHeldItem() != null?1:0;
            if(entityLiving instanceof EntityPlayer && ((EntityPlayer)entityLiving).getItemInUseDuration() > 0)
            {
               EnumAction enumaction = ((EntityPlayer)entityLiving).getItemInUse().getItemUseAction();
               if(enumaction == EnumAction.BLOCK)
               {
                  this.modelJayGarrick2.heldItemRight = 3;
               }
               else if(enumaction == EnumAction.BOW)
               {
                  this.modelJayGarrick2.aimedBow = true;
               }
            }
    		return modelJayGarrick2;

    Rename the modelJayGarrick2 to model, otherwise, it completely defeats the purpose of what we've done.

    Posted in: Modification Development
  • 0

    posted a message on Custom Armor Model

    Click here for example.


    Take note in this case I just made random boxes for the boots so I could test it out, but you might want to change the boot boxes up a bit as they are a bit weird.


    EDIT: Congratz m9 on ur 404 posts. Lel :lol:


    Also, in the future if you plan on adding more custom modeled armors you might want to make a custom armor model base that implements boots and the stuff from the model biped so you don't need to add it every single armor class, but that is just a suggestion, by all means you do not have to do that. Lol I edited this post like literally 10+ times along with my gist just to make sure it worked for you. Gosh, by now this thread has practically turned into a how to make 3D armor models 1.8.9. Hehe.

    Posted in: Modification Development
  • 0

    posted a message on Custom Armor Model

    Well, we set the boots part of the model as a child of the legs. If you still don't get what I mean submit your updated code and I will write in an example of what I mean.

    Posted in: Modification Development
  • 0

    posted a message on Custom Armor Model

    Oh we give it a value later on with:

     int type = ((ItemArmor)itemStack.getItem()).armorType;
    
     if(this.model1 == null) {
     this.model1 = new ModelJayGarrick(0.5F);
     if(type == 0) {
     this.model = this.model1;
     } 
    Posted in: Modification Development
  • 0

    posted a message on Custom Armor Model

    Like you could do something like this:

       ModelBiped model1 = null;
       ModelBiped model = null;


    And then in your getArmorModel:

     int type = ((ItemArmor)itemStack.getItem()).armorType;
    
     if(this.model1 == null) {
     this.model1 = new ModelJayGarrick(0.5F);
     if(type == 0) {
     this.model = this.model1;
     } 

    And in your ModelJayGarrick2 class just add something like:

    if(f == 0.5){
    //register boots part of the model here.
    }
    Posted in: Modification Development
  • 0

    posted a message on Custom Armor Model

    Ahh. What you can do is in your super you know that float f in your model class? just make it so if get armor boots then the float = like 0.5 or whatever and if the float is 0.5 in your model class then call your boots part of the model. And trim the legs part of the model if you want it to be similar to Minecraft. Or if you are feeling cheeky you could just make a new armor class that is just boots and just use the vanilla model and trim your legs part of the model in your other armor class.

    Posted in: Modification Development
  • 1

    posted a message on Custom Armor Model

    Oh!!!! I just saw your armor class! Delete this:

    		if(armorSlot == 2)
    		{
    			return modelJayGarrick2;
    		}

    Because it is rendering the model again with the incorrect rotations and sizing, thus giving baby parasite models.

    Posted in: Modification Development
  • 0

    posted a message on Custom Armor Model

    Oh my god! I completely forgot about that! Do you have your updated class?

    Posted in: Modification Development
  • 0

    posted a message on Custom Armor Model

    Hmmm... I'm going to tinker around with GL11 and see if I can get anywhere.

    Posted in: Modification Development
  • 1

    posted a message on Custom Armor Model

    Yay! The head works so that is good.


    You should also put a super in your model class. After public ModelJayGarrick:

    super(0, 0, 64, 64);
    Posted in: Modification Development
  • To post a comment, please .