package com.minelittlepony.pony.data;

import net.minecraft.client.entity.AbstractClientPlayer;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.util.ResourceLocation;
import net.minecraft.util.math.AxisAlignedBB;
import net.minecraft.util.math.Vec3d;

import com.minelittlepony.MineLittlePony;

public interface IPony {
    /**
     * Gets or creates a new pony associated with the provided player.
     * The results of this method should not be cached.
     */
    static IPony forPlayer(AbstractClientPlayer player) {
        return MineLittlePony.getInstance().getManager().getPony(player);
    }

    /**
     * Returns true if the provided entity is flying like a pegasus.
     * True if the entity is off the ground, has race with wings.
     * Creative flight counts only if the entity is <i>not</i> on the ground.
     *
     * Entities that are riding, climbing a ladder, or swimming are <i>not</i> flying.
     */
    boolean isPegasusFlying(EntityLivingBase entity);

    /**
     * Returns true if the provided antity is actively wimming.
     * That is, it should be fully submerged (isFullySubmerged returns true)
     * and is not standing on the (river) bed or riding a ladder or any other entity.
     */
    boolean isSwimming(EntityLivingBase entity);

    /**
     * Returns true if the provided entity is fully submerged with water reaching the entity's eyeheight or above.
     */
    boolean isFullySubmerged(EntityLivingBase entity);

    /**
     * Returns true if an entity is wearing any headgear. This is used to hide things like the snout when wearing items
     * such as the pumpkin, a player's head, or any other types of blocks.
     *
     * In this case the helmet does <i>not</i> count as headgear because those generally don't interfere with snuzzle rendering.
     */
    boolean isWearingHeadgear(EntityLivingBase entity);

    /**
     * Gets the race associated with this pony.
     *
     * @param ignorePony    True to ignore the client's current pony level setting.
     */
    PonyRace getRace(boolean ignorePony);

    /**
     * Returns true if an entity is riding a pony or other sentient life-form.
     *
     * Boats do not count.
     */
    boolean isRidingInteractive(EntityLivingBase entity);

    /**
     * Returns the pony this entity is currently riding if any.
     */
    IPony getMountedPony(EntityLivingBase entity);

    /**
     * Gets the texture used for rendering this pony.
     */
    ResourceLocation getTexture();

    /**
     * Gets the metadata associated with this pony's model texture.
     */
    IPonyData getMetadata();

    /**
     * Gets the riding offset of this entity relative to its lowermost mount.
     */
    Vec3d getAbsoluteRidingOffset(EntityLivingBase entity);

    /**
     * Gets the actual bounding box of this entity as a pony.
     */
    AxisAlignedBB getComputedBoundingBox(EntityLivingBase entity);
}

@@ -614,16 +614,309 @@
 %0A    %7D%0A%0A
+    /**%0A     * Gets or creates a new pony associated with the provided resource location.%0A     * The results of this method should not be cached.%0A     */%0A    static IPony forResource(ResourceLocation texture) %7B%0A        return MineLittlePony.getInstance().getManager().getPony(texture);%0A    %7D%0A%0A
     /**%0A

Add an interface method for getting an IPony from an already existing resource