public abstract class MixinEntity extends Object implements org.spongepowered.api.entity.Entity, IMixinEntity
Modifier and Type | Field and Description |
---|---|
protected net.minecraft.entity.DataWatcher |
dataWatcher |
float |
fallDistance |
int |
fire |
int |
fireResistance |
float |
height |
int |
hurtResistantTime |
boolean |
inWater |
boolean |
isDead |
double |
motionX |
double |
motionY |
double |
motionZ |
boolean |
onGround |
double |
posX |
double |
posY |
double |
posZ |
double |
prevPosX |
double |
prevPosY |
double |
prevPosZ |
protected Random |
rand |
net.minecraft.entity.Entity |
riddenByEntity |
net.minecraft.entity.Entity |
ridingEntity |
float |
rotationPitch |
float |
rotationYaw |
float |
width |
net.minecraft.world.World |
worldObj |
Constructor and Description |
---|
MixinEntity() |
Modifier and Type | Method and Description |
---|---|
abstract int |
getAir() |
protected abstract boolean |
getAlwaysRenderNameTag() |
org.spongepowered.api.entity.Entity |
getBaseVehicle() |
Collection<org.spongepowered.api.data.manipulator.DataManipulator<?,?>> |
getContainers() |
abstract String |
getCustomNameTag() |
abstract float |
getEyeHeight() |
abstract boolean |
getFlag(int flag) |
org.spongepowered.api.world.Location<org.spongepowered.api.world.World> |
getLocation() |
com.flowpowered.math.vector.Vector3d |
getPosition() |
com.flowpowered.math.vector.Vector3d |
getRotation() |
com.flowpowered.math.vector.Vector3d |
getScale() |
net.minecraft.entity.Entity |
getTeleportVehicle() |
org.spongepowered.api.entity.Transform<org.spongepowered.api.world.World> |
getTransform() |
org.spongepowered.api.entity.EntityType |
getType() |
UUID |
getUniqueId() |
abstract UUID |
getUniqueID() |
com.flowpowered.math.vector.Vector3d |
getVelocity() |
org.spongepowered.api.world.World |
getWorld() |
boolean |
isLoaded() |
boolean |
isOnGround() |
boolean |
isRemoved() |
boolean |
isTeleporting() |
abstract void |
mountEntity(net.minecraft.entity.Entity entityIn) |
void |
onGetEyeHeight(org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable<Float> ci) |
void |
onMoveEntity(double x,
double y,
double z,
org.spongepowered.asm.mixin.injection.callback.CallbackInfo ci) |
void |
onReadFromNBT(net.minecraft.nbt.NBTTagCompound compound,
org.spongepowered.asm.mixin.injection.callback.CallbackInfo ci)
Hooks into vanilla's readFromNBT to call
readFromNbt(net.minecraft.nbt.NBTTagCompound) . |
void |
onSetSize(float width,
float height,
org.spongepowered.asm.mixin.injection.callback.CallbackInfo ci) |
void |
onWriteToNBT(net.minecraft.nbt.NBTTagCompound compound,
org.spongepowered.asm.mixin.injection.callback.CallbackInfo ci)
Hooks into vanilla's writeToNBT to call
writeToNbt(net.minecraft.nbt.NBTTagCompound) . |
void |
readFromNbt(net.minecraft.nbt.NBTTagCompound compound)
Read extra data (SpongeData) from the entity's NBT tag.
|
void |
remove() |
abstract void |
setAir(int air) |
protected abstract void |
setAlwaysRenderNameTag(boolean visible) |
abstract void |
setCustomNameTag(String name) |
abstract void |
setDead() |
void |
setEyeHeight(Double value) |
abstract void |
setFlag(int flag,
boolean data) |
void |
setIsTeleporting(boolean teleporting) |
void |
setLocation(org.spongepowered.api.world.Location<org.spongepowered.api.world.World> location) |
boolean |
setLocation(org.spongepowered.api.world.Location<org.spongepowered.api.world.World> location,
boolean forced) |
void |
setLocationAndRotation(org.spongepowered.api.world.Location<org.spongepowered.api.world.World> location,
com.flowpowered.math.vector.Vector3d rotation) |
void |
setLocationAndRotation(org.spongepowered.api.world.Location<org.spongepowered.api.world.World> location,
com.flowpowered.math.vector.Vector3d rotation,
EnumSet<org.spongepowered.api.util.RelativePositions> relativePositions) |
boolean |
setLocationAndRotation(org.spongepowered.api.world.Location<org.spongepowered.api.world.World> location,
com.flowpowered.math.vector.Vector3d rotation,
EnumSet<org.spongepowered.api.util.RelativePositions> relativePositions,
boolean forced) |
boolean |
setLocationAndRotationSafely(org.spongepowered.api.world.Location<org.spongepowered.api.world.World> location,
com.flowpowered.math.vector.Vector3d rotation) |
boolean |
setLocationAndRotationSafely(org.spongepowered.api.world.Location<org.spongepowered.api.world.World> location,
com.flowpowered.math.vector.Vector3d rotation,
EnumSet<org.spongepowered.api.util.RelativePositions> relativePositions) |
boolean |
setLocationSafely(org.spongepowered.api.world.Location<org.spongepowered.api.world.World> location) |
boolean |
setPassenger(org.spongepowered.api.entity.Entity entity) |
abstract void |
setPosition(double x,
double y,
double z) |
void |
setRawData(org.spongepowered.api.data.DataContainer container) |
void |
setRotation(com.flowpowered.math.vector.Vector3d rotation) |
void |
setScale(com.flowpowered.math.vector.Vector3d scale) |
void |
setTeleportVehicle(net.minecraft.entity.Entity vehicle) |
void |
setTransform(org.spongepowered.api.entity.Transform<org.spongepowered.api.world.World> transform) |
boolean |
setVehicle(org.spongepowered.api.entity.Entity entity) |
void |
setVelocity(com.flowpowered.math.vector.Vector3d velocity) |
protected abstract void |
shadow$setRotation(float yaw,
float pitch) |
boolean |
teleportEntity(net.minecraft.entity.Entity entity,
org.spongepowered.api.world.Location<org.spongepowered.api.world.World> location,
int currentDim,
int targetDim,
boolean forced) |
org.spongepowered.api.data.DataContainer |
toContainer() |
boolean |
transferToWorld(String worldName,
com.flowpowered.math.vector.Vector3d position) |
boolean |
transferToWorld(UUID uuid,
com.flowpowered.math.vector.Vector3d position) |
boolean |
validateRawData(org.spongepowered.api.data.DataContainer container) |
void |
writeToNbt(net.minecraft.nbt.NBTTagCompound compound)
Write extra data (SpongeData) to the entity's NBT tag.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
copyFrom, copyFrom, get, getOrCreate, offer, offer, offer, offer, offer, offer, remove, remove, remove, supports, transform, undo
copy, get, getKeys, getOrElse, getOrNull, getValue, getValues, supports, supports
getActivatedTick, getActivationType, getDefaultActivationState, getSpongeData, inactiveTick, setActivatedTick
public net.minecraft.world.World worldObj
public double posX
public double posY
public double posZ
public double motionX
public double motionY
public double motionZ
public double prevPosX
public double prevPosY
public double prevPosZ
public float rotationYaw
public float rotationPitch
public float width
public float height
public float fallDistance
public boolean isDead
public boolean onGround
public boolean inWater
public int hurtResistantTime
public int fireResistance
public int fire
public net.minecraft.entity.Entity riddenByEntity
public net.minecraft.entity.Entity ridingEntity
protected net.minecraft.entity.DataWatcher dataWatcher
protected Random rand
public abstract void setPosition(double x, double y, double z)
public abstract void mountEntity(net.minecraft.entity.Entity entityIn)
public abstract void setDead()
public abstract void setFlag(int flag, boolean data)
public abstract boolean getFlag(int flag)
public abstract int getAir()
public abstract void setAir(int air)
public abstract float getEyeHeight()
public abstract String getCustomNameTag()
public abstract void setCustomNameTag(String name)
public abstract UUID getUniqueID()
protected abstract boolean getAlwaysRenderNameTag()
protected abstract void setAlwaysRenderNameTag(boolean visible)
protected abstract void shadow$setRotation(float yaw, float pitch)
public void onSetSize(float width, float height, org.spongepowered.asm.mixin.injection.callback.CallbackInfo ci)
public void onMoveEntity(double x, double y, double z, org.spongepowered.asm.mixin.injection.callback.CallbackInfo ci)
public void onGetEyeHeight(org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable<Float> ci)
public void setEyeHeight(Double value)
setEyeHeight
in interface IMixinEntity
public org.spongepowered.api.world.World getWorld()
getWorld
in interface org.spongepowered.api.entity.Entity
public com.flowpowered.math.vector.Vector3d getPosition()
public org.spongepowered.api.world.Location<org.spongepowered.api.world.World> getLocation()
getLocation
in interface org.spongepowered.api.entity.Entity
public void setLocation(org.spongepowered.api.world.Location<org.spongepowered.api.world.World> location)
setLocation
in interface org.spongepowered.api.entity.Entity
public boolean setLocationSafely(org.spongepowered.api.world.Location<org.spongepowered.api.world.World> location)
setLocationSafely
in interface org.spongepowered.api.entity.Entity
public void setLocationAndRotation(org.spongepowered.api.world.Location<org.spongepowered.api.world.World> location, com.flowpowered.math.vector.Vector3d rotation)
setLocationAndRotation
in interface org.spongepowered.api.entity.Entity
public boolean setLocationAndRotationSafely(org.spongepowered.api.world.Location<org.spongepowered.api.world.World> location, com.flowpowered.math.vector.Vector3d rotation)
setLocationAndRotationSafely
in interface org.spongepowered.api.entity.Entity
public boolean setLocationAndRotationSafely(org.spongepowered.api.world.Location<org.spongepowered.api.world.World> location, com.flowpowered.math.vector.Vector3d rotation, EnumSet<org.spongepowered.api.util.RelativePositions> relativePositions)
setLocationAndRotationSafely
in interface org.spongepowered.api.entity.Entity
public boolean setLocation(org.spongepowered.api.world.Location<org.spongepowered.api.world.World> location, boolean forced)
public void setLocationAndRotation(org.spongepowered.api.world.Location<org.spongepowered.api.world.World> location, com.flowpowered.math.vector.Vector3d rotation, EnumSet<org.spongepowered.api.util.RelativePositions> relativePositions)
setLocationAndRotation
in interface org.spongepowered.api.entity.Entity
public boolean setLocationAndRotation(org.spongepowered.api.world.Location<org.spongepowered.api.world.World> location, com.flowpowered.math.vector.Vector3d rotation, EnumSet<org.spongepowered.api.util.RelativePositions> relativePositions, boolean forced)
public com.flowpowered.math.vector.Vector3d getScale()
getScale
in interface org.spongepowered.api.entity.Entity
public void setScale(com.flowpowered.math.vector.Vector3d scale)
setScale
in interface org.spongepowered.api.entity.Entity
public org.spongepowered.api.entity.Transform<org.spongepowered.api.world.World> getTransform()
getTransform
in interface org.spongepowered.api.entity.Entity
public void setTransform(org.spongepowered.api.entity.Transform<org.spongepowered.api.world.World> transform)
setTransform
in interface org.spongepowered.api.entity.Entity
public boolean transferToWorld(String worldName, com.flowpowered.math.vector.Vector3d position)
transferToWorld
in interface org.spongepowered.api.entity.Entity
public boolean transferToWorld(UUID uuid, com.flowpowered.math.vector.Vector3d position)
transferToWorld
in interface org.spongepowered.api.entity.Entity
public com.flowpowered.math.vector.Vector3d getRotation()
getRotation
in interface org.spongepowered.api.entity.Entity
public void setRotation(com.flowpowered.math.vector.Vector3d rotation)
setRotation
in interface org.spongepowered.api.entity.Entity
public boolean isOnGround()
isOnGround
in interface org.spongepowered.api.entity.Entity
public boolean isRemoved()
isRemoved
in interface org.spongepowered.api.entity.Entity
public boolean isLoaded()
isLoaded
in interface org.spongepowered.api.entity.Entity
public void remove()
remove
in interface org.spongepowered.api.entity.Entity
public boolean isTeleporting()
isTeleporting
in interface IMixinEntity
public net.minecraft.entity.Entity getTeleportVehicle()
getTeleportVehicle
in interface IMixinEntity
public void setIsTeleporting(boolean teleporting)
setIsTeleporting
in interface IMixinEntity
public void setTeleportVehicle(net.minecraft.entity.Entity vehicle)
setTeleportVehicle
in interface IMixinEntity
public org.spongepowered.api.entity.EntityType getType()
getType
in interface org.spongepowered.api.entity.Entity
public UUID getUniqueId()
getUniqueId
in interface org.spongepowered.api.util.Identifiable
public com.flowpowered.math.vector.Vector3d getVelocity()
public void setVelocity(com.flowpowered.math.vector.Vector3d velocity)
public org.spongepowered.api.entity.Entity getBaseVehicle()
public boolean setPassenger(@Nullable org.spongepowered.api.entity.Entity entity)
public boolean setVehicle(@Nullable org.spongepowered.api.entity.Entity entity)
public boolean teleportEntity(net.minecraft.entity.Entity entity, org.spongepowered.api.world.Location<org.spongepowered.api.world.World> location, int currentDim, int targetDim, boolean forced)
public void onWriteToNBT(net.minecraft.nbt.NBTTagCompound compound, org.spongepowered.asm.mixin.injection.callback.CallbackInfo ci)
writeToNbt(net.minecraft.nbt.NBTTagCompound)
.
This makes it easier for other entity mixins to override writeToNBT
without having to specify the @Inject
annotation.
compound
- The compound vanilla writes to (unused because we write
to SpongeData)ci
- (Unused) callback infopublic void onReadFromNBT(net.minecraft.nbt.NBTTagCompound compound, org.spongepowered.asm.mixin.injection.callback.CallbackInfo ci)
readFromNbt(net.minecraft.nbt.NBTTagCompound)
.
This makes it easier for other entity mixins to override readFromNbt
without having to specify the @Inject
annotation.
compound
- The compound vanilla reads from (unused because we read
from SpongeData)ci
- (Unused) callback infopublic boolean validateRawData(org.spongepowered.api.data.DataContainer container)
validateRawData
in interface org.spongepowered.api.data.DataHolder
public void setRawData(org.spongepowered.api.data.DataContainer container) throws org.spongepowered.api.service.persistence.InvalidDataException
setRawData
in interface org.spongepowered.api.data.DataHolder
org.spongepowered.api.service.persistence.InvalidDataException
public void readFromNbt(net.minecraft.nbt.NBTTagCompound compound)
readFromNbt
in interface IMixinEntity
compound
- The SpongeData compound to read frompublic void writeToNbt(net.minecraft.nbt.NBTTagCompound compound)
writeToNbt
in interface IMixinEntity
compound
- The SpongeData compound to write topublic org.spongepowered.api.data.DataContainer toContainer()
toContainer
in interface org.spongepowered.api.data.DataSerializable
public Collection<org.spongepowered.api.data.manipulator.DataManipulator<?,?>> getContainers()
getContainers
in interface org.spongepowered.api.data.value.mutable.CompositeValueStore<org.spongepowered.api.data.DataHolder,org.spongepowered.api.data.manipulator.DataManipulator<?,?>>