public abstract class NPCAbstract<N extends NPCEntity,B extends org.bukkit.entity.Entity> extends Object
Modifier and Type | Field and Description |
---|---|
protected org.inventivetalent.reflection.resolver.FieldResolver |
entityFieldResolver |
protected org.inventivetalent.reflection.resolver.MethodResolver |
entityMethodResolver |
protected org.inventivetalent.nbt.annotation.AnnotatedNBTHandler |
nbtHandler |
protected org.inventivetalent.reflection.resolver.FieldResolver |
npcEntityFieldResolver |
protected org.inventivetalent.reflection.resolver.MethodResolver |
npcEntityMethodResolver |
protected String |
pluginName |
Constructor and Description |
---|
NPCAbstract(N npcEntity) |
Modifier and Type | Method and Description |
---|---|
protected void |
broadcastGlobalPacket(Object packet) |
protected void |
broadcastPacket(Object packet) |
void |
despawn() |
org.inventivetalent.boundingbox.BoundingBox |
getAbsoluteBoundingBox() |
org.inventivetalent.boundingbox.BoundingBox |
getBoundingBox() |
B |
getBukkitEntity() |
Object |
getEntityField(String field) |
org.bukkit.entity.EntityType |
getEntityType() |
String |
getName() |
org.inventivetalent.nbt.CompoundTag |
getNbtData() |
N |
getNpcEntity() |
Object |
getNPCField(String field) |
NPCType |
getNpcType() |
org.bukkit.plugin.Plugin |
getPlugin() |
UUID |
getUniqueId() |
Object |
invokeEntityMethod(String method,
Class<?>[] types,
Object[] args) |
Object |
invokeEntityMethod(String method,
Object... args) |
Object |
invokeNPCMethod(String method,
Class<?>[] types,
Object[] args) |
Object |
invokeNPCMethod(String method,
Object... args) |
boolean |
isNameVisible() |
boolean |
isPersistent() |
void |
onBaseTick(SuperSwitch superSwitch) |
void |
onCollide(ObjectContainer<Object> entity) |
Boolean |
onDamage(ObjectContainer<Object> damageSource,
ObjectContainer<Float> amount,
SuperSwitch superSwitch) |
void |
onDie(SuperSwitch superSwitch) |
void |
onMotion(ObjectContainer<Double> x,
ObjectContainer<Double> y,
ObjectContainer<Double> z,
SuperSwitch superSwitch) |
void |
onMove(ObjectContainer<Double> x,
ObjectContainer<Double> y,
ObjectContainer<Double> z,
SuperSwitch superSwitch) |
void |
onNBTRead(ObjectContainer<Object> nbtTagCompound) |
void |
onNBTWrite(ObjectContainer<Object> nbtTagCompound) |
void |
playAnimation(Animation animation,
org.bukkit.entity.Player player) |
void |
postInit(org.bukkit.plugin.Plugin plugin,
org.bukkit.Location location) |
protected void |
postInit(String pluginName,
double x,
double y,
double z,
float yaw,
float pitch) |
void |
readFromNBT(org.inventivetalent.nbt.CompoundTag compoundTag) |
<A extends NPCAbstract<N,B>> |
registerAI(AIAbstract<A> aiAbstract) |
void |
respawnTo(org.bukkit.entity.Player player) |
protected void |
sendPacket(org.bukkit.entity.Player player,
Object packet) |
void |
setEntityField(String field,
Object value) |
void |
setMotion(double x,
double y,
double z) |
void |
setName(String name) |
void |
setNameVisible(boolean visible) |
void |
setNPCField(String field,
Object value) |
void |
setPersistent(boolean persistent) |
void |
spawn() |
void |
tickAI() |
String |
toString() |
void |
updateNearby() |
void |
updateNearby(double radius) |
void |
updateNearby(double radius,
com.google.common.base.Predicate<org.bukkit.entity.Player> predicate) |
void |
updateToPlayer(org.bukkit.entity.Player player) |
void |
writeToNBT(org.inventivetalent.nbt.CompoundTag compoundTag) |
protected final org.inventivetalent.reflection.resolver.FieldResolver npcEntityFieldResolver
protected final org.inventivetalent.reflection.resolver.MethodResolver npcEntityMethodResolver
protected final org.inventivetalent.reflection.resolver.FieldResolver entityFieldResolver
protected final org.inventivetalent.reflection.resolver.MethodResolver entityMethodResolver
protected String pluginName
protected org.inventivetalent.nbt.annotation.AnnotatedNBTHandler nbtHandler
public NPCAbstract(N npcEntity)
public void postInit(org.bukkit.plugin.Plugin plugin, org.bukkit.Location location) throws Exception
Exception
protected void postInit(String pluginName, double x, double y, double z, float yaw, float pitch) throws Exception
Exception
public org.inventivetalent.nbt.CompoundTag getNbtData()
public UUID getUniqueId()
public void spawn()
public void despawn()
public <A extends NPCAbstract<N,B>> boolean registerAI(AIAbstract<A> aiAbstract)
public void tickAI()
public org.inventivetalent.boundingbox.BoundingBox getAbsoluteBoundingBox()
public org.inventivetalent.boundingbox.BoundingBox getBoundingBox()
public void setName(String name)
public String getName()
public void setNameVisible(boolean visible)
public boolean isNameVisible()
public void setPersistent(boolean persistent)
public boolean isPersistent()
public void playAnimation(Animation animation, org.bukkit.entity.Player player)
public NPCType getNpcType()
public org.bukkit.entity.EntityType getEntityType()
public void onBaseTick(SuperSwitch superSwitch)
public void setMotion(double x, double y, double z)
public void onMove(ObjectContainer<Double> x, ObjectContainer<Double> y, ObjectContainer<Double> z, SuperSwitch superSwitch)
public void onMotion(ObjectContainer<Double> x, ObjectContainer<Double> y, ObjectContainer<Double> z, SuperSwitch superSwitch)
public void onCollide(ObjectContainer<Object> entity)
public Boolean onDamage(ObjectContainer<Object> damageSource, ObjectContainer<Float> amount, SuperSwitch superSwitch)
public void onDie(SuperSwitch superSwitch)
public void onNBTWrite(ObjectContainer<Object> nbtTagCompound)
public void onNBTRead(ObjectContainer<Object> nbtTagCompound)
public void writeToNBT(org.inventivetalent.nbt.CompoundTag compoundTag)
public void readFromNBT(org.inventivetalent.nbt.CompoundTag compoundTag)
public void updateToPlayer(org.bukkit.entity.Player player)
public void respawnTo(org.bukkit.entity.Player player)
public void updateNearby(double radius, com.google.common.base.Predicate<org.bukkit.entity.Player> predicate)
public void updateNearby(double radius)
public void updateNearby()
public org.bukkit.plugin.Plugin getPlugin()
public N getNpcEntity()
public B getBukkitEntity()
protected void broadcastGlobalPacket(Object packet)
protected void broadcastPacket(Object packet)
protected void sendPacket(org.bukkit.entity.Player player, Object packet)
Copyright © 2018. All rights reserved.