MineLittlePony/src/main/java/com/minelittlepony/api/pony/IPony.java

52 lines
1.2 KiB
Java
Raw Normal View History

2020-04-03 23:54:12 +02:00
package com.minelittlepony.api.pony;
2019-05-27 17:59:15 +02:00
import net.minecraft.util.Identifier;
2020-04-03 23:54:12 +02:00
import com.minelittlepony.api.pony.meta.Race;
import com.minelittlepony.client.MineLittlePony;
public interface IPony {
/**
* Gets the global pony manager instance.
*/
static IPonyManager getManager() {
return MineLittlePony.getInstance().getManager();
}
/**
* Gets or creates a new pony associated with the provided resource location.
* The results of this method should not be cached.
*
* @deprecated User IPony.getManager().getPony(texture) instead
*/
@Deprecated
2019-05-27 17:59:15 +02:00
static IPony forResource(Identifier texture) {
return getManager().getPony(texture);
}
/**
* Returns whether this is one of the default ponies assigned to a player without a custom skin.
*/
boolean defaulted();
/**
* Returns whether this pony's metadata block has been initialized.
*/
boolean hasMetadata();
/**
* Gets the race associated with this pony.
*/
Race race();
/**
* Gets the texture used for rendering this pony.
*/
Identifier texture();
/**
* Gets the metadata associated with this pony's model texture.
*/
IPonyData metadata();
}