Entity API Documentation

This commit is contained in:
Kam committed 2025-03-06 01:48:39 -05:00
1 parent 3593a09d1d
commit 8c2c226d34
21 files changed
+2778 -1142

No files matched your search

+29 -12
View File
@@ -1,12 +1,29 @@
package noppes.npcs.api.entity;
import net.minecraft.entity.monster.EntityMob;
public interface IVillager<T extends EntityMob> extends IEntityLiving<T>{
int getProfession();
boolean getIsTrading();
IEntityLivingBase getCustomer();
}
package noppes.npcs.api.entity;
import net.minecraft.entity.passive.EntityVillager;
import noppes.npcs.api.entity.IEntityLivingBase;
/**
* Represents a villager entity with additional trading-related methods.
*
* @param <T> The underlying Minecraft EntityVillager type.
*/
public interface IVillager<T extends EntityVillager> extends IEntityLiving<T> {
/**
* @return The profession of the villager.
*/
int getProfession();
/**
* @return true if the villager is currently trading.
*/
boolean getIsTrading();
/**
* Returns the customer (player) who is currently trading with the villager.
*
* @return the customer as an IEntityLivingBase.
*/
IEntityLivingBase getCustomer();
}