package com.zivilon.cinder_loe.client.render.corrupt;

import com.zivilon.cinder_loe.entity.corrupt.CorruptDwarf;
import com.zivilon.cinder_loe.entity.corrupt.CorruptHobbit;
import lotr.client.model.LOTRModelDwarf;
import lotr.client.model.LOTRModelHobbit;
import lotr.client.render.entity.LOTRRandomSkins;
import lotr.client.render.entity.LOTRRenderBiped;
import lotr.client.render.entity.LOTRRenderHobbit;
import net.minecraft.client.model.ModelBase;
import net.minecraft.client.model.ModelBiped;
import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityLiving;
import net.minecraft.util.ResourceLocation;

public class RenderCorruptHobbit extends LOTRRenderHobbit {
    public static LOTRRandomSkins hobbitSkinsMale;
    public static LOTRRandomSkins hobbitSkinsFemale;
    protected ModelBiped outfitModel = new LOTRModelHobbit(0.5f, 64, 64);

    public RenderCorruptHobbit() {
        super();
        hobbitSkinsMale = LOTRRandomSkins.loadSkinsList("cinder_loe:mob/corrupt/hobbit_male");
        hobbitSkinsFemale = LOTRRandomSkins.loadSkinsList("cinder_loe:mob/corrupt/hobbit_female");

    }

    @Override
    protected void func_82421_b() {
        this.field_82423_g = new LOTRModelHobbit(1.0f);
        this.field_82425_h = new LOTRModelHobbit(0.5f);
    }

    @Override
    public ResourceLocation getEntityTexture(Entity entity) {
        CorruptHobbit dwarf = (CorruptHobbit) entity;
        if (dwarf.familyInfo.isMale()) {
            return hobbitSkinsMale.getRandomSkin(dwarf);
        }
        return hobbitSkinsFemale.getRandomSkin(dwarf);
    }
}
