Package net.minecraft.src
Class EntityXPOrb
java.lang.Object
net.minecraft.src.Entity
net.minecraft.src.EntityXPOrb
-
Field Summary
FieldsModifier and TypeFieldDescriptionintbooleanintA constantly increasing value that RenderXPOrb uses to control the colour shifting (Green / yellow)intThe age of the XP orb in ticks.intThis is how much XP this orb has.Fields inherited from class net.minecraft.src.Entity
addedToChunk, boundingBox, chunkCoordX, chunkCoordY, chunkCoordZ, dataWatcher, dimension, distanceWalkedModified, distanceWalkedOnStepModified, entityCollisionReduction, entityId, fallDistance, field_70135_K, fireResistance, forceSpawn, height, hurtResistantTime, ignoreFrustumCheck, inPortal, inWater, isAirBorne, isCollided, isCollidedHorizontally, isCollidedVertically, isDead, isImmuneToFire, isInWeb, lastGroundPosX, lastGroundPosY, lastGroundPosZ, lastTickPosX, lastTickPosY, lastTickPosZ, motionX, motionY, motionZ, myEntitySize, nextBlockCheckDistance, noClip, onGround, portalCounter, posX, posY, posZ, prevDistanceWalkedModified, preventEntitySpawning, prevPosX, prevPosY, prevPosZ, prevRotationPitch, prevRotationYaw, rand, renderDistanceWeight, riddenByEntity, ridingEntity, rotationPitch, rotationYaw, serverPosX, serverPosY, serverPosZ, stepHeight, teleportDirection, ticksExisted, timeUntilPortal, velocityChanged, width, worldObj, yOffset, ySize -
Constructor Summary
ConstructorsConstructorDescriptionEntityXPOrb(World par1World) EntityXPOrb(World par1World, double par2, double par4, double par6, int par8) EntityXPOrb(World par1World, double par2, double par4, double par6, int par8, boolean bNotPlayerOwned) -
Method Summary
Modifier and TypeMethodDescriptionbooleanattackEntityFrom(DamageSource par1DamageSource, float par2) Called when the entity is attacked.booleanIf returns false, the item will not inflict any damage against entities.protected booleanreturns if this entity triggers Block.onEntityWalking on the blocks they walk on. used for spiders and wolves to prevent them from trampling cropsvoiddealFireDamage(int par1) Will deal the specified amount of damage to the entity if the entity isn't immune to fire damage.protected void// +++START EDIT+++ // ---END EDIT--- Checks for block collisions, and calls the associated onBlockCollided method for the collided block.protected voidintgetBrightnessForRender(float par1) intReturns a number from 1 to 10 based on how much XP this orb is worth.static intgetXPSplit(int par0) Get xp split rate (Is called until the xp drop code in EntityLiving.onEntityUpdate is complete)intReturns the XP value of this XP orb.booleanReturns if this entity is in water and will end up adding the waters velocity to the entityvoidonCollideWithPlayer(EntityPlayer par1EntityPlayer) Called by a player entity when they collide with an entityvoidonUpdate()Called to update the entity's position/logic.protected booleanpushOutOfBlocks(double par1, double par3, double par5) Adds velocity to push the entity out of blocks at the specified x, y, z position Args: x, y, zvoidreadEntityFromNBT(NBTTagCompound par1NBTTagCompound) (abstract) Protected helper method to read subclass entity data from NBT.voidwriteEntityToNBT(NBTTagCompound par1NBTTagCompound) (abstract) Protected helper method to write subclass entity data to NBT.Methods inherited from class net.minecraft.src.Entity
addComponent, addEntityCrashInfo, addToPlayerScore, addVelocity, appliesConstantForceWhenRidingBoat, applyEntityCollision, attractsLightning, canBeCollidedWith, canBePushed, canCollideWithEntity, canEntityTriggerTripwire, canRenderOnFire, copyDataFrom, copyLocationAndAnglesFrom, doesEntityApplyToSpawnCap, doesEntityApplyToSquidPossessionCap, doesEntityNotTriggerPressurePlate, doesNotDismountInWater, dropItem, dropItemWithOffset, entityDropItem, equals, extinguish, fall, flagAllWatchedObjectsDirty, flingAwayFromEntity, getAir, getAnimalKickMovementMultiplier, getBlockExplosionResistance, getBoundingBox, getBrightness, getCanBeHeadCrabbed, getCollisionBorderSize, getCollisionBox, getComponent, getDataWatcher, getDistance, getDistanceSq, getDistanceSqToEntity, getDistanceToEntity, getEntityName, getEntityString, getEyeHeight, getFlag, getHeadCrabSharedAttackTarget, getLastActiveItems, getLookVec, getMaxInPortalTime, getMaxSafePointTries, getMountedYOffset, getParts, getPortalCooldown, getRotationYawHead, getShadowSize, getTeleportDirection, getTranslatedEntityName, getUniqueID, getVisualBoundingBox, getXZDistanceSqToEntity, getYOffset, handleHealthUpdate, handleLavaMovement, hasComponent, hashCode, hasHeadCrabbedSquid, hitByEntity, initComponents, interactFirst, isAffectedByMovementModifiers, isBeingRainedOn, isBurning, isEating, isEntityAlive, isEntityEqual, isEntityInsideOpaqueBlock, isEntityInsideOpaqueBlock, isEntityInsideSuffocatingBlock, isEntityInsideSuffocatingBlock, isEntityInvulnerable, isImmuneToFire, isImmuneToHeadCrabDamage, isInRangeToRenderDist, isInRangeToRenderVec3D, isInsideOfMaterial, isInvisible, isInvisibleToPlayer, isInWater, isItemEntity, isOffsetPositionInLiquid, isPushedByWater, isRiding, isSecondaryTargetForSquid, isSneaking, isSprinting, isUsingSpecialKey, isValidOngoingAttackTargetForSquid, isValidZombieSecondaryTarget, isWet, kill, mountEntity, mountEntityRemote, moveEntity, moveFlying, movementModifierWhenRidingBoat, newDoubleNBTList, newFloatNBTList, notifyOfWolfHowl, onBlockDispenserConsume, onChunkLoad, onEntityUpdate, onFlungBySquidTentacle, onHeadCrabbedBySquid, onKickedByAnimal, onKillEntity, onPossessedRidingEntityDeath, onStruckByLightning, outOfUpdateRangeUpdate, performHurtAnimation, playSound, playStepSound, preparePlayerToSpawn, readFromNBT, setAir, setAngles, setBeenAttacked, setCurrentItemOrArmor, setDead, setEating, setFire, setFlag, setInPortal, setInvisible, setInWeb, setLocationAndAngles, setOnFireFromLava, setPosition, setPositionAndRotation, setPositionAndRotation2, setRotation, setRotationYawHead, setSize, setSneaking, setSprinting, setVelocity, setWorld, shouldExplodeBlock, shouldSetPosAfterLoading, shouldSetPositionOnLoad, toString, travelToDimension, tryToSetFireToBlocksInContact, updateCloak, updateFallState, updateRidden, updateRiderPosition, writeMountToNBT, writeToNBT, writeToNBTOptional
-
Field Details
-
notPlayerOwned
public boolean notPlayerOwned -
xpColor
public int xpColorA constantly increasing value that RenderXPOrb uses to control the colour shifting (Green / yellow) -
xpOrbAge
public int xpOrbAgeThe age of the XP orb in ticks. -
field_70532_c
public int field_70532_c -
xpValue
public int xpValueThis is how much XP this orb has.
-
-
Constructor Details
-
EntityXPOrb
public EntityXPOrb(World par1World, double par2, double par4, double par6, int par8, boolean bNotPlayerOwned) -
EntityXPOrb
-
EntityXPOrb
-
-
Method Details
-
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:
canTriggerWalkingin classEntity
-
entityInit
protected void entityInit()- Specified by:
entityInitin classEntity
-
getBrightnessForRender
public int getBrightnessForRender(float par1) - Overrides:
getBrightnessForRenderin classEntity
-
onUpdate
public void onUpdate()Called to update the entity's position/logic. -
handleWaterMovement
public boolean handleWaterMovement()Returns if this entity is in water and will end up adding the waters velocity to the entity- Overrides:
handleWaterMovementin classEntity
-
dealFireDamage
public void dealFireDamage(int par1) Will deal the specified amount of damage to the entity if the entity isn't immune to fire damage. Args: amountDamage- Overrides:
dealFireDamagein classEntity
-
attackEntityFrom
Called when the entity is attacked.- Overrides:
attackEntityFromin classEntity
-
pushOutOfBlocks
protected boolean pushOutOfBlocks(double par1, double par3, double par5) Description copied from class:EntityAdds velocity to push the entity out of blocks at the specified x, y, z position Args: x, y, z- Overrides:
pushOutOfBlocksin classEntity
-
writeEntityToNBT
(abstract) Protected helper method to write subclass entity data to NBT.- Specified by:
writeEntityToNBTin classEntity
-
readEntityFromNBT
(abstract) Protected helper method to read subclass entity data from NBT.- Specified by:
readEntityFromNBTin classEntity
-
onCollideWithPlayer
Called by a player entity when they collide with an entity- Overrides:
onCollideWithPlayerin classEntity
-
getXpValue
public int getXpValue()Returns the XP value of this XP orb. -
getTextureByXP
public int getTextureByXP()Returns a number from 1 to 10 based on how much XP this orb is worth. This is used by RenderXPOrb to determine what texture to use. -
getXPSplit
public static int getXPSplit(int par0) Get xp split rate (Is called until the xp drop code in EntityLiving.onEntityUpdate is complete) -
canAttackWithItem
public boolean canAttackWithItem()If returns false, the item will not inflict any damage against entities.- Overrides:
canAttackWithItemin classEntity
-
doBlockCollisions
protected void doBlockCollisions()Description copied from class:Entity// +++START EDIT+++ // ---END EDIT--- Checks for block collisions, and calls the associated onBlockCollided method for the collided block.- Overrides:
doBlockCollisionsin classEntity
-