Package net.minecraft.entity.item
Class EntityItem
- java.lang.Object
-
- net.zxmushroom63.plugins.BaseData
-
- net.zxmushroom63.plugins.PluginData
-
- net.minecraft.entity.Entity
-
- net.minecraft.entity.item.EntityItem
-
- All Implemented Interfaces:
org.teavm.jso.JSObject
public class EntityItem extends Entity
+ This portion of EaglercraftX contains deobfuscated Minecraft 1.8 source code. Minecraft 1.8.8 bytecode is (c) 2015 Mojang AB. "Do not distribute!" Mod Coder Pack v9.18 deobfuscation configs are (c) Copyright by the MCP Team EaglercraftX 1.8 patch files are (c) 2022-2023 LAX1DUDE. All Rights Reserved. WITH THE EXCEPTION OF PATCH FILES, MINIFIED JAVASCRIPT, AND ALL FILES NORMALLY FOUND IN AN UNMODIFIED MINECRAFT RESOURCE PACK, YOU ARE NOT ALLOWED TO SHARE, DISTRIBUTE, OR REPURPOSE ANY FILE USED BY OR PRODUCED BY THE SOFTWARE IN THIS REPOSITORY WITHOUT PRIOR PERMISSION FROM THE PROJECT AUTHOR. NOT FOR COMMERCIAL OR MALICIOUS USE (please read the 'LICENSE' file this repo's root directory for more info)
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class net.zxmushroom63.plugins.BaseData
BaseData.BooleanCallback, BaseData.BooleanCallbackArr, BaseData.DataBooleanCallback, BaseData.DataBooleanCallbackArr, BaseData.DataDoubleCallback, BaseData.DataDoubleCallbackArr, BaseData.DataFloatCallback, BaseData.DataFloatCallbackArr, BaseData.DataIntCallback, BaseData.DataIntCallbackArr, BaseData.DataObjectCallback, BaseData.DataObjectCallbackArr, BaseData.DataStringCallback, BaseData.DataStringCallbackArr, BaseData.DataVoidCallback, BaseData.DoubleCallback, BaseData.DoubleCallbackArr, BaseData.FloatCallback, BaseData.FloatCallbackArr, BaseData.IntCallback, BaseData.IntCallbackArr, BaseData.ObjectCallback, BaseData.ObjectCallbackArr, BaseData.StringCallback, BaseData.StringCallbackArr, BaseData.VoidCallback
-
-
Field Summary
Fields Modifier and Type Field Description float
hoverStart
-
Fields inherited from class net.minecraft.entity.Entity
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 Summary
Constructors Constructor Description EntityItem(World worldIn)
EntityItem(World worldIn, double x, double y, double z)
EntityItem(World worldIn, double x, double y, double z, ItemStack stack)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
attackEntityFrom(DamageSource damagesource, float f)
+ Called when the entity is attacked.boolean
canAttackWithItem()
+ If returns false, the item will not inflict any damage against entities.boolean
cannotPickup()
protected boolean
canTriggerWalking()
+ returns if this entity triggers Block.onEntityWalking on the blocks they walk on.protected void
dealFireDamage(int i)
+ Will deal the specified amount of damage to the entity if the entity isn't immune to fire damage.protected void
entityInit()
void
func_174870_v()
int
getAge()
ItemStack
getEntityItem()
+ Returns the ItemStack corresponding to the Entity (Note: if no item exists, will log an error but still return an ItemStack containing Block.stone)java.lang.String
getName()
+ Gets the name of this command sender (usually username, but possibly "Rcon")java.lang.String
getOwner()
java.lang.String
getThrower()
boolean
handleWaterMovement()
+ Returns if this entity is in water and will end up adding the waters velocity to the entityvoid
onCollideWithPlayer(EntityPlayer entityplayer)
+ Called by a player entity when they collide with an entityvoid
onUpdate()
+ Called to update the entity's position/logic.void
readEntityFromNBT(NBTTagCompound nbttagcompound)
+ (abstract) Protected helper method to read subclass entity data from NBT.void
setAgeToCreativeDespawnTime()
+ sets the age of the item so that it'll despawn one minute after it has been dropped (instead of five).void
setDefaultPickupDelay()
void
setEntityItemStack(ItemStack stack)
+ Sets the ItemStack for this entityvoid
setInfinitePickupDelay()
void
setNoDespawn()
void
setNoPickupDelay()
void
setOwner(java.lang.String owner)
void
setPickupDelay(int ticks)
void
setThrower(java.lang.String thrower)
void
writeEntityToNBT(NBTTagCompound nbttagcompound)
+ (abstract) Protected helper method to write subclass entity data to NBT.-
Methods inherited from class net.minecraft.entity.Entity
addChatMessage, addEntityCrashInfo, addToPlayerScore, addVelocity, applyEnchantments, applyEntityCollision, canBeCollidedWith, canBePushed, canCommandSenderUseCommand, canRenderOnFire, clientUpdateEntityNBT, copyDataFromOld, copyLocationAndAnglesFrom, createRunningParticles, doBlockCollisions, doesEntityNotTriggerPressurePlate, dropItem, dropItemWithOffset, entityDropItem, equals, extinguish, fall, fromNBT, func_181012_aH, func_181013_g, func_181014_aG, func_181015_d, getAir, getAlwaysRenderNameTag, getAlwaysRenderNameTagForRender, getBrightness, getBrightnessForRender, getCollisionBorderSize, getCollisionBoundingBox, getCollisionBox, getCommandSenderEntity, getCustomNameTag, getDataWatcher, getDisplayName, getDistance, getDistanceSq, getDistanceSq, getDistanceSqToCenter, getDistanceSqToEntity, getDistanceToEntity, getEntityBoundingBox, getEntityId, getEntityString, getEntityWorld, getExplosionResistance, getEyeHeight, getFlag, getHorizontalFacing, getHoverEvent, getInventory, getLook, getLookVec, getMaxFallHeight, getMaxInPortalTime, getMountedYOffset, getNBTTagCompound, getParts, getPortalCooldown, getPosition, getPositionEyes, getPositionVector, getRotationYawHead, getSplashSound, getSwimSound, getUniqueID, getVectorForRotation, getYOffset, handleStatusUpdate, hasCustomName, 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, isSprinting, isWet, kill, loadPluginData, makePluginData, mountEntity, moveEntity, moveFlying, moveToBlockPosAndAngles, newDoubleNBTList, newFloatNBTList, onChunkLoad, onDataWatcherUpdate, onEntityUpdate, onKillCommand, onKillEntity, onStruckByLightning, performHurtAnimation, playSound, playStepSound, preparePlayerToSpawn, pushOutOfBlocks, rayTrace, readFromNBT, replaceItemInInventory, resetHeight, sendCommandFeedback, setAir, setAlwaysRenderNameTag, setAngles, setBeenAttacked, setCurrentItemOrArmor, setCustomNameTag, setDead, setEating, setEntityBoundingBox, setEntityId, setFire, setFlag, setInvisible, setInWeb, setLocationAndAngles, setOnFireFromLava, setOutsideBorder, setPosition, setPositionAndRotation, setPositionAndRotation2, setPositionAndUpdate, setRotation, setRotationYawHead, setSilent, setSize, setSneaking, setSprinting, setVelocity, setWorld, shouldSetPosAfterLoading, spawnRunningParticles, toNBT, toString, travelToDimension, updateFallState, updateRidden, updateRiderPosition, verifyExplosion, writeMountToNBT, writeToNBT, writeToNBTOptional
-
Methods inherited from class net.zxmushroom63.plugins.BaseData
execFuncBaseData, execFuncObject, execFuncString, getBaseData, getBaseDataArr, getBoolean, getBooleanArr, getByte, getByteArr, getChar, getCharArr, getDouble, getDoubleArr, getFloat, getFloatArr, getInt, getIntArr, getObject, getObjectArr, getShort, getShortArr, getString, getStringArr, has, set, set, set, set, set, set, set, set, set, set, set, set, set, set, set, set, set, set, set, set, setCallbackBoolean, setCallbackBooleanArr, setCallbackBooleanArrWithDataArg, setCallbackBooleanWithDataArg, setCallbackDouble, setCallbackDoubleArr, setCallbackDoubleArrWithDataArg, setCallbackDoubleWithDataArg, setCallbackFloat, setCallbackFloatArr, setCallbackFloatArrWithDataArg, setCallbackFloatWithDataArg, setCallbackInt, setCallbackIntArr, setCallbackIntArrWithDataArg, setCallbackIntWithDataArg, setCallbackObject, setCallbackObjectArr, setCallbackObjectArrWithDataArg, setCallbackObjectWithDataArg, setCallbackString, setCallbackStringArr, setCallbackStringArrWithDataArg, setCallbackStringWithDataArg, setCallbackVoid, setCallbackVoidWithDataArg, setNull
-
-
-
-
Method Detail
-
canTriggerWalking
protected boolean canTriggerWalking()
+ returns if this entity triggers Block.onEntityWalking on the blocks they walk on. used for spiders and wolves to prevent them from trampling crops- Overrides:
canTriggerWalking
in classEntity
-
entityInit
protected void entityInit()
- Specified by:
entityInit
in classEntity
-
onUpdate
public void onUpdate()
+ Called to update the entity's position/logic.
-
setAgeToCreativeDespawnTime
public void setAgeToCreativeDespawnTime()
+ sets the age of the item so that it'll despawn one minute after it has been dropped (instead of five). Used when items are dropped from players in creative mode
-
handleWaterMovement
public boolean handleWaterMovement()
+ Returns if this entity is in water and will end up adding the waters velocity to the entity- Overrides:
handleWaterMovement
in classEntity
-
dealFireDamage
protected void dealFireDamage(int i)
+ Will deal the specified amount of damage to the entity if the entity isn't immune to fire damage. Args: amountDamage- Overrides:
dealFireDamage
in classEntity
-
attackEntityFrom
public boolean attackEntityFrom(DamageSource damagesource, float f)
+ Called when the entity is attacked.- Overrides:
attackEntityFrom
in classEntity
-
writeEntityToNBT
public void writeEntityToNBT(NBTTagCompound nbttagcompound)
+ (abstract) Protected helper method to write subclass entity data to NBT.- Specified by:
writeEntityToNBT
in classEntity
-
readEntityFromNBT
public void readEntityFromNBT(NBTTagCompound nbttagcompound)
+ (abstract) Protected helper method to read subclass entity data from NBT.- Specified by:
readEntityFromNBT
in classEntity
-
onCollideWithPlayer
public void onCollideWithPlayer(EntityPlayer entityplayer)
+ Called by a player entity when they collide with an entity- Overrides:
onCollideWithPlayer
in classEntity
-
getName
public java.lang.String getName()
+ Gets the name of this command sender (usually username, but possibly "Rcon")
-
canAttackWithItem
public boolean canAttackWithItem()
+ If returns false, the item will not inflict any damage against entities.- Overrides:
canAttackWithItem
in classEntity
-
getEntityItem
public ItemStack getEntityItem()
+ Returns the ItemStack corresponding to the Entity (Note: if no item exists, will log an error but still return an ItemStack containing Block.stone)
-
setEntityItemStack
public void setEntityItemStack(ItemStack stack)
+ Sets the ItemStack for this entity
-
getOwner
public java.lang.String getOwner()
-
setOwner
public void setOwner(java.lang.String owner)
-
getThrower
public java.lang.String getThrower()
-
setThrower
public void setThrower(java.lang.String thrower)
-
getAge
public int getAge()
-
setDefaultPickupDelay
public void setDefaultPickupDelay()
-
setNoPickupDelay
public void setNoPickupDelay()
-
setInfinitePickupDelay
public void setInfinitePickupDelay()
-
setPickupDelay
public void setPickupDelay(int ticks)
-
cannotPickup
public boolean cannotPickup()
-
setNoDespawn
public void setNoDespawn()
-
func_174870_v
public void func_174870_v()
-
-