package com.zivilon.cinder_loe.entity.corrupt;

import com.zivilon.cinder_loe.CinderLoE;
import com.zivilon.cinder_loe.CinderLoE_Config;
import lotr.common.LOTRFoods;
import lotr.common.LOTRMod;
import lotr.common.entity.ai.LOTREntityAIAttackOnCollide;
import lotr.common.entity.npc.LOTREntityDwarf;
import lotr.common.entity.npc.LOTREntityOrc;
import lotr.common.entity.npc.LOTRNames;
import lotr.common.fac.LOTRFaction;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.entity.IEntityLivingData;
import net.minecraft.entity.SharedMonsterAttributes;
import net.minecraft.entity.ai.EntityAIBase;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.util.MovingObjectPosition;
import net.minecraft.world.World;

public class CorruptOrc extends LOTREntityOrc {
    private LOTRFaction faction;
    public CorruptOrc(World world) {
        super(world);
    }
    @Override
    public ItemStack getPickedResult(MovingObjectPosition target) {
        return null;
    }
    @Override
    public EntityAIBase createOrcAttackAI() {
        return new LOTREntityAIAttackOnCollide(this, 1.4, false);
    }
    @Override
    protected void applyEntityAttributes() {
        super.applyEntityAttributes();
        this.getEntityAttribute(SharedMonsterAttributes.maxHealth).setBaseValue(20.0);
    }

    @Override
    public LOTRFaction getFaction() {
        return LOTRFaction.valueOf(CinderLoE_Config.corrupt_faction);
    }

    @Override
    public String getHurtSound() {
        return "lotr:orc.hurt";
    }
    @Override
    public String getDeathSound() {
        return "lotr:orc.death";
    }

    @Override
    public String getAttackSound() {
        return "lotr:orc.attack";
    }
    @Override
    public void onKillEntity(EntityLivingBase entity) {
        super.onKillEntity(entity);
        this.playSound("lotr:orc.kill", this.getSoundVolume(), this.getSoundPitch());
    }
    @Override
    public String getSpeechBank(EntityPlayer entityplayer) {
        if (this.isFriendlyAndAligned(entityplayer)) {
            return "corruptSpeak/all/neutral";
        }
        return "corruptSpeak/all/hostile";
    }
    @Override
    public float getAlignmentBonus() {
        return 0.0f;
    }

    @Override
    public void attackEntityWithRangedAttack(EntityLivingBase p_82196_1_, float p_82196_2_) {

    }
    @Override
    protected void dropFewItems(boolean flag, int i) {
        super.dropFewItems(flag, i);
    }
    @Override
    protected void dropOrcItems(boolean flag, int i) {
        super.dropOrcItems(flag, i);
    }
}
