net.minecraft.entity.projectile

## Class EntityArrow

- java.lang.Object
- - net.minecraft.entity.Entity
  - - net.minecraft.entity.projectile.EntityArrow

- All Implemented Interfaces:
    IProjectile

      public class EntityArrow
      extends Entity
      implements IProjectile

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `int` | `arrowShake` Seems to be some sort of timer for animating an arrow.
    `int` | `canBePickedUp` 1 if the player can pick up the arrow
    `Entity` | `shootingEntity` The owner of this arrow.

    - ### Fields inherited from class net.minecraft.entity.Entity

      `addedToChunk, boundingBox, capturedDrops, captureDrops, chunkCoordX, chunkCoordY, chunkCoordZ, dimension, distanceWalkedModified, distanceWalkedOnStepModified, entityCollisionReduction, entityId, fallDistance, field_70135_K, fireResistance, forceSpawn, height, hurtResistantTime, ignoreFrustumCheck, isAirBorne, isCollided, isCollidedHorizontally, isCollidedVertically, isDead, lastTickPosX, lastTickPosY, lastTickPosZ, motionX, motionY, motionZ, myEntitySize, noClip, onGround, posX, posY, posZ, prevDistanceWalkedModified, preventEntitySpawning, prevPosX, prevPosY, prevPosZ, prevRotationPitch, prevRotationYaw, renderDistanceWeight, riddenByEntity, ridingEntity, rotationPitch, rotationYaw, serverPosX, serverPosY, serverPosZ, stepHeight, ticksExisted, timeUntilPortal, velocityChanged, width, worldObj, yOffset, ySize`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `EntityArrow(World par1World)`
    `EntityArrow(World par1World, double par2, double par4, double par6)`
    `EntityArrow(World par1World, EntityLivingBase par2EntityLivingBase, EntityLivingBase par3EntityLivingBase, float par4, float par5)`
    `EntityArrow(World par1World, EntityLivingBase par2EntityLivingBase, float par3)`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `canAttackWithItem()` If returns false, the item will not inflict any damage against entities.
    `double` | `getDamage()`
    `boolean` | `getIsCritical()` Whether the arrow has a stream of critical hit particles flying behind it.
    `float` | `getShadowSize()`
    `void` | `onCollideWithPlayer(EntityPlayer par1EntityPlayer)` Called by a player entity when they collide with an entity
    `void` | `onUpdate()` Called to update the entity's position/logic.
    `void` | `readEntityFromNBT(NBTTagCompound par1NBTTagCompound)` (abstract) Protected helper method to read subclass entity data from NBT.
    `void` | `setDamage(double par1)`
    `void` | `setIsCritical(boolean par1)` Whether the arrow has a stream of critical hit particles flying behind it.
    `void` | `setKnockbackStrength(int par1)` Sets the amount of knockback the arrow applies when it hits a mob.
    `void` | `setPositionAndRotation2(double par1, double par3, double par5, float par7, float par8, int par9)`
    `void` | `setThrowableHeading(double par1, double par3, double par5, float par7, float par8)` Similar to setArrowHeading, it's point the throwable entity to a x, y, z direction.
    `void` | `setVelocity(double par1, double par3, double par5)`
    `void` | `writeEntityToNBT(NBTTagCompound par1NBTTagCompound)` (abstract) Protected helper method to write subclass entity data to NBT.

    - ### Methods inherited from class net.minecraft.entity.Entity

      `addEntityCrashInfo, addToPlayerScore, addVelocity, applyEntityCollision, attackEntityFrom, canBeCollidedWith, canBePushed, canRenderOnFire, canRiderInteract, copyDataFrom, copyLocationAndAnglesFrom, doesEntityNotTriggerPressurePlate, dropItem, dropItemWithOffset, entityDropItem, equals, extinguish, getAir, getBlockExplosionResistance, getBoundingBox, getBrightness, getBrightnessForRender, getCollisionBorderSize, getCollisionBox, getDataWatcher, getDistance, getDistanceSq, getDistanceSqToEntity, getDistanceToEntity, getEntityData, getEntityName, getExtendedProperties, getEyeHeight, getLastActiveItems, getLookVec, getMaxInPortalTime, getMaxSafePointTries, getMountedYOffset, getParts, getPersistentID, getPickedResult, getPortalCooldown, getRotationYawHead, getTeleportDirection, getTranslatedEntityName, getUniqueID, getYOffset, handleHealthUpdate, handleLavaMovement, handleWaterMovement, hashCode, hitByEntity, interactFirst, isBurning, isCreatureType, isEating, isEntityAlive, isEntityEqual, isEntityInsideOpaqueBlock, isEntityInvulnerable, isImmuneToFire, isInRangeToRenderDist, isInRangeToRenderVec3D, isInsideOfMaterial, isInvisible, isInvisibleToPlayer, isInWater, isOffsetPositionInLiquid, isPushedByWater, isRiding, isSneaking, isSprinting, isWet, mountEntity, moveEntity, moveFlying, onChunkLoad, onEntityUpdate, onKillEntity, onStruckByLightning, performHurtAnimation, playSound, readFromNBT, registerExtendedProperties, resetEntityId, setAir, setAngles, setCurrentItemOrArmor, setDead, setEating, setFire, setInPortal, setInvisible, setInWeb, setLocationAndAngles, setPosition, setPositionAndRotation, setRotationYawHead, setSneaking, setSprinting, setWorld, shouldDismountInWater, shouldExplodeBlock, shouldRenderInPass, shouldRiderSit, toString, travelToDimension, updateRidden, updateRiderPosition, writeMountToNBT, writeToNBT, writeToNBTOptional`

    - ### Methods inherited from class java.lang.Object

      `getClass, notify, notifyAll, wait, wait, wait`

- - ### Field Detail

    - #### canBePickedUp

          public int canBePickedUp

      1 if the player can pick up the arrow

    - #### arrowShake

          public int arrowShake

      Seems to be some sort of timer for animating an arrow.

    - #### shootingEntity

          public Entity shootingEntity

      The owner of this arrow.

  - ### Constructor Detail

    - #### EntityArrow

          public EntityArrow(World par1World)

    - #### EntityArrow

          public EntityArrow(World par1World,
                     double par2,
                     double par4,
                     double par6)

    - #### EntityArrow

          public EntityArrow(World par1World,
                     EntityLivingBase par2EntityLivingBase,
                     EntityLivingBase par3EntityLivingBase,
                     float par4,
                     float par5)

    - #### EntityArrow

          public EntityArrow(World par1World,
                     EntityLivingBase par2EntityLivingBase,
                     float par3)

  - ### Method Detail

    - #### setThrowableHeading

          public void setThrowableHeading(double par1,
                                 double par3,
                                 double par5,
                                 float par7,
                                 float par8)

      Similar to setArrowHeading, it's point the throwable entity to a x, y, z direction.
      Specified by:
        `setThrowableHeading` in interface `IProjectile`

    - #### setPositionAndRotation2

          public void setPositionAndRotation2(double par1,
                                     double par3,
                                     double par5,
                                     float par7,
                                     float par8,
                                     int par9)

      Overrides:
        `setPositionAndRotation2` in class `Entity`

    - #### setVelocity

          public void setVelocity(double par1,
                         double par3,
                         double par5)

      Overrides:
        `setVelocity` in class `Entity`

    - #### onUpdate

          public void onUpdate()

      Called to update the entity's position/logic.
      Overrides:
        `onUpdate` in class `Entity`

    - #### writeEntityToNBT

          public void writeEntityToNBT(NBTTagCompound par1NBTTagCompound)

      (abstract) Protected helper method to write subclass entity data to NBT.

    - #### readEntityFromNBT

          public void readEntityFromNBT(NBTTagCompound par1NBTTagCompound)

      (abstract) Protected helper method to read subclass entity data from NBT.

    - #### onCollideWithPlayer

          public void onCollideWithPlayer(EntityPlayer par1EntityPlayer)

      Called by a player entity when they collide with an entity
      Overrides:
        `onCollideWithPlayer` in class `Entity`

    - #### getShadowSize

          public float getShadowSize()

      Overrides:
        `getShadowSize` in class `Entity`

    - #### setDamage

          public void setDamage(double par1)

    - #### getDamage

          public double getDamage()

    - #### setKnockbackStrength

          public void setKnockbackStrength(int par1)

      Sets the amount of knockback the arrow applies when it hits a mob.

    - #### canAttackWithItem

          public boolean canAttackWithItem()

      If returns false, the item will not inflict any damage against entities.
      Overrides:
        `canAttackWithItem` in class `Entity`

    - #### setIsCritical

          public void setIsCritical(boolean par1)

      Whether the arrow has a stream of critical hit particles flying behind it.

    - #### getIsCritical

          public boolean getIsCritical()

      Whether the arrow has a stream of critical hit particles flying behind it.