public abstract class EntityMinecart extends Entity implements IWorldNameable
Modifier and Type | Class and Description |
---|---|
static class |
EntityMinecart.EnumMinecartType |
Modifier and Type | Field and Description |
---|---|
private java.lang.String |
entityName |
private boolean |
isInReverse |
private static int[][][] |
matrix
Minecart rotational logic matrix
|
private double |
minecartPitch |
private double |
minecartX |
private double |
minecartY |
private double |
minecartYaw |
private double |
minecartZ |
private int |
turnProgress
appears to be the progress of the turn
|
private double |
velocityX |
private double |
velocityY |
private double |
velocityZ |
addedToChunk, chunkCoordX, chunkCoordY, chunkCoordZ, dataWatcher, dimension, distanceWalkedModified, distanceWalkedOnStepModified, entityCollisionReduction, entityUniqueID, fallDistance, field_181016_an, field_181017_ao, field_181018_ap, fireResistance, firstUpdate, forceSpawn, height, hurtResistantTime, ignoreFrustumCheck, inPortal, inWater, isAirBorne, isCollided, isCollidedHorizontally, isCollidedVertically, isDead, isImmuneToFire, isInWeb, lastTickPosX, lastTickPosY, lastTickPosZ, motionX, motionY, motionZ, noClip, onGround, portalCounter, posX, posY, posZ, prevDistanceWalkedModified, preventEntitySpawning, prevPosX, prevPosY, prevPosZ, prevRotationPitch, prevRotationYaw, rand, renderDistanceWeight, riddenByEntity, ridingEntity, rotationPitch, rotationYaw, serverPosX, serverPosY, serverPosZ, stepHeight, ticksExisted, timeUntilPortal, velocityChanged, width, worldObj
Constructor and Description |
---|
EntityMinecart(World worldIn) |
EntityMinecart(World worldIn,
double x,
double y,
double z) |
Modifier and Type | Method and Description |
---|---|
protected void |
applyDrag() |
void |
applyEntityCollision(Entity entityIn)
Applies a velocity to each of the entities pushing them away from each other.
|
boolean |
attackEntityFrom(DamageSource source,
float amount)
Called when the entity is attacked.
|
boolean |
canBeCollidedWith()
Returns true if other Entities should be prevented from moving through this Entity.
|
boolean |
canBePushed()
Returns true if this entity should push and be pushed by other entities when colliding.
|
protected boolean |
canTriggerWalking()
returns if this entity triggers Block.onEntityWalking on the blocks they walk on.
|
protected void |
entityInit() |
void |
func_174899_a(IBlockState p_174899_1_) |
static EntityMinecart |
func_180458_a(World worldIn,
double p_180458_1_,
double p_180458_3_,
double p_180458_5_,
EntityMinecart.EnumMinecartType p_180458_7_) |
protected void |
func_180460_a(BlockPos p_180460_1_,
IBlockState p_180460_2_) |
Vec3 |
func_70489_a(double p_70489_1_,
double p_70489_3_,
double p_70489_5_) |
Vec3 |
func_70495_a(double p_70495_1_,
double p_70495_3_,
double p_70495_5_,
double p_70495_7_) |
AxisAlignedBB |
getCollisionBoundingBox()
Returns the collision bounding box for this entity
|
AxisAlignedBB |
getCollisionBox(Entity entityIn)
Returns a boundingBox used to collide the entity with other entities and blocks.
|
java.lang.String |
getCustomNameTag() |
float |
getDamage()
Gets the current amount of damage the minecart has taken.
|
IBlockState |
getDefaultDisplayTile() |
int |
getDefaultDisplayTileOffset() |
IChatComponent |
getDisplayName()
Get the formatted ChatComponent that will be used for the sender's username in chat
|
IBlockState |
getDisplayTile() |
int |
getDisplayTileOffset() |
protected double |
getMaximumSpeed()
Get's the maximum speed for a minecart
|
abstract EntityMinecart.EnumMinecartType |
getMinecartType() |
double |
getMountedYOffset()
Returns the Y offset from the entity's position for any entity riding this one.
|
java.lang.String |
getName()
Gets the name of this command sender (usually username, but possibly "Rcon")
|
int |
getRollingAmplitude()
Gets the rolling amplitude the cart rolls while being attacked.
|
int |
getRollingDirection()
Gets the rolling direction the cart rolls while being attacked.
|
boolean |
hasCustomName()
Returns true if this thing is named
|
boolean |
hasDisplayTile() |
void |
killMinecart(DamageSource p_94095_1_) |
protected void |
moveDerailedMinecart()
Moves a minecart that is not attached to a rail
|
void |
onActivatorRailPass(int x,
int y,
int z,
boolean receivingPower)
Called every tick the minecart is on an activator rail.
|
void |
onUpdate()
Called to update the entity's position/logic.
|
void |
performHurtAnimation()
Setups the entity to do the hurt animation.
|
protected void |
readEntityFromNBT(NBTTagCompound tagCompund)
(abstract) Protected helper method to read subclass entity data from NBT.
|
void |
setCustomNameTag(java.lang.String name)
Sets the custom name tag for this entity
|
void |
setDamage(float p_70492_1_)
Sets the current amount of damage the minecart has taken.
|
void |
setDead()
Will get destroyed next tick.
|
void |
setDisplayTileOffset(int p_94086_1_) |
void |
setHasDisplayTile(boolean p_94096_1_) |
void |
setPosition(double x,
double y,
double z)
Sets the x,y,z of the entity from the given parameters.
|
void |
setPositionAndRotation2(double x,
double y,
double z,
float yaw,
float pitch,
int posRotationIncrements,
boolean p_180426_10_) |
void |
setRollingAmplitude(int p_70497_1_)
Sets the rolling amplitude the cart rolls while being attacked.
|
void |
setRollingDirection(int p_70494_1_)
Sets the rolling direction the cart rolls while being attacked.
|
void |
setVelocity(double x,
double y,
double z)
Sets the velocity to the args.
|
protected void |
writeEntityToNBT(NBTTagCompound tagCompound)
(abstract) Protected helper method to write subclass entity data to NBT.
|
addChatMessage, addEntityCrashInfo, addToPlayerScore, addVelocity, applyEnchantments, canAttackWithItem, canCommandSenderUseCommand, canRenderOnFire, clientUpdateEntityNBT, copyDataFromOld, copyLocationAndAnglesFrom, createRunningParticles, dealFireDamage, doBlockCollisions, doesEntityNotTriggerPressurePlate, dropItem, dropItemWithOffset, entityDropItem, equals, extinguish, fall, func_174817_o, func_181012_aH, func_181013_g, func_181014_aG, func_181015_d, getAir, getAlwaysRenderNameTag, getAlwaysRenderNameTagForRender, getBrightness, getBrightnessForRender, getCollisionBorderSize, getCommandSenderEntity, getCommandStats, getDataWatcher, getDistance, getDistanceSq, getDistanceSq, getDistanceSqToCenter, getDistanceSqToEntity, getDistanceToEntity, getEntityBoundingBox, getEntityId, getEntityString, getEntityWorld, getExplosionResistance, getEyeHeight, getFlag, getHorizontalFacing, getHoverEvent, getInventory, getLook, getLookVec, getMaxFallHeight, getMaxInPortalTime, getNBTTagCompound, getParts, getPortalCooldown, getPosition, getPositionEyes, getPositionVector, getRotationYawHead, getSplashSound, getSwimSound, getUniqueID, getVectorForRotation, getYOffset, handleStatusUpdate, handleWaterMovement, hashCode, hitByEntity, interactAt, interactFirst, isBurning, isEating, isEntityAlive, isEntityEqual, isEntityInsideOpaqueBlock, isEntityInvulnerable, isImmuneToExplosions, isImmuneToFire, isInLava, isInRangeToRender3d, isInRangeToRenderDist, isInsideOfMaterial, isInvisible, isInvisibleToPlayer, isInWater, isOffsetPositionInLiquid, isOutsideBorder, isPushedByWater, isRiding, isSilent, isSneaking, isSpectatedByPlayer, isSprinting, isWet, kill, mountEntity, moveEntity, moveFlying, moveToBlockPosAndAngles, newDoubleNBTList, newFloatNBTList, onChunkLoad, onCollideWithPlayer, onDataWatcherUpdate, onEntityUpdate, onKillCommand, onKillEntity, onStruckByLightning, playSound, playStepSound, preparePlayerToSpawn, pushOutOfBlocks, rayTrace, readFromNBT, replaceItemInInventory, resetHeight, sendCommandFeedback, setAir, setAlwaysRenderNameTag, setAngles, setBeenAttacked, setCommandStat, setCurrentItemOrArmor, setEating, setEntityBoundingBox, setEntityId, setFire, setFlag, setInvisible, setInWeb, setLocationAndAngles, setOnFireFromLava, setOutsideBorder, setPositionAndRotation, setPositionAndUpdate, setRotation, setRotationYawHead, setSilent, setSize, setSneaking, setSprinting, setWorld, shouldSetPosAfterLoading, spawnRunningParticles, toString, travelToDimension, updateFallState, updateRidden, updateRiderPosition, verifyExplosion, writeMountToNBT, writeToNBT, writeToNBTOptional
private boolean isInReverse
private java.lang.String entityName
private static final int[][][] matrix
private int turnProgress
private double minecartX
private double minecartY
private double minecartZ
private double minecartYaw
private double minecartPitch
private double velocityX
private double velocityY
private double velocityZ
public EntityMinecart(World worldIn)
public EntityMinecart(World worldIn, double x, double y, double z)
public static EntityMinecart func_180458_a(World worldIn, double p_180458_1_, double p_180458_3_, double p_180458_5_, EntityMinecart.EnumMinecartType p_180458_7_)
protected boolean canTriggerWalking()
canTriggerWalking
in class Entity
protected void entityInit()
entityInit
in class Entity
public AxisAlignedBB getCollisionBox(Entity entityIn)
getCollisionBox
in class Entity
public AxisAlignedBB getCollisionBoundingBox()
getCollisionBoundingBox
in class Entity
public boolean canBePushed()
canBePushed
in class Entity
public double getMountedYOffset()
getMountedYOffset
in class Entity
public boolean attackEntityFrom(DamageSource source, float amount)
attackEntityFrom
in class Entity
public void killMinecart(DamageSource p_94095_1_)
public void performHurtAnimation()
performHurtAnimation
in class Entity
public boolean canBeCollidedWith()
canBeCollidedWith
in class Entity
public void onUpdate()
protected double getMaximumSpeed()
public void onActivatorRailPass(int x, int y, int z, boolean receivingPower)
protected void moveDerailedMinecart()
protected void func_180460_a(BlockPos p_180460_1_, IBlockState p_180460_2_)
protected void applyDrag()
public void setPosition(double x, double y, double z)
setPosition
in class Entity
public Vec3 func_70495_a(double p_70495_1_, double p_70495_3_, double p_70495_5_, double p_70495_7_)
public Vec3 func_70489_a(double p_70489_1_, double p_70489_3_, double p_70489_5_)
protected void readEntityFromNBT(NBTTagCompound tagCompund)
readEntityFromNBT
in class Entity
protected void writeEntityToNBT(NBTTagCompound tagCompound)
writeEntityToNBT
in class Entity
public void applyEntityCollision(Entity entityIn)
applyEntityCollision
in class Entity
public void setPositionAndRotation2(double x, double y, double z, float yaw, float pitch, int posRotationIncrements, boolean p_180426_10_)
setPositionAndRotation2
in class Entity
public void setVelocity(double x, double y, double z)
setVelocity
in class Entity
public void setDamage(float p_70492_1_)
public float getDamage()
public void setRollingAmplitude(int p_70497_1_)
public int getRollingAmplitude()
public void setRollingDirection(int p_70494_1_)
public int getRollingDirection()
public abstract EntityMinecart.EnumMinecartType getMinecartType()
public IBlockState getDisplayTile()
public IBlockState getDefaultDisplayTile()
public int getDisplayTileOffset()
public int getDefaultDisplayTileOffset()
public void func_174899_a(IBlockState p_174899_1_)
public void setDisplayTileOffset(int p_94086_1_)
public boolean hasDisplayTile()
public void setHasDisplayTile(boolean p_94096_1_)
public void setCustomNameTag(java.lang.String name)
setCustomNameTag
in class Entity
public java.lang.String getName()
getName
in interface ICommandSender
getName
in interface IWorldNameable
getName
in class Entity
public boolean hasCustomName()
hasCustomName
in interface IWorldNameable
hasCustomName
in class Entity
public java.lang.String getCustomNameTag()
getCustomNameTag
in class Entity
public IChatComponent getDisplayName()
getDisplayName
in interface ICommandSender
getDisplayName
in interface IWorldNameable
getDisplayName
in class Entity