Attributable
, CommandSender
, Damageable
, Entity
, LivingEntity
, Metadatable
, Nameable
, Permissible
, ProjectileSource
, SentientNPC
, ServerOperator
Illusioner
, Llama
, Skeleton
, Snowman
, Stray
, Witch
, Wither
, WitherSkeleton
public interface RangedEntity extends SentientNPC
Entity.Spigot
Modifier and Type | Method | Description |
---|---|---|
default boolean |
isChargingAttack() |
Alias to
LivingEntity.isHandRaised() , if the entity is charging an attack |
void |
rangedAttack(LivingEntity target,
float charge) |
Attack the specified entity using a ranged attack.
|
void |
setChargingAttack(boolean raiseHands) |
Sets that the Entity is "charging" up an attack, by raising its hands
|
getAttribute
getName, sendMessage, sendMessage, sendMessage, sendMessage
damage, damage, getHealth, getMaxHealth, resetMaxHealth, setHealth, setMaxHealth
addPassenger, addScoreboardTag, eject, fromMobSpawner, getChunk, getEntityId, getFallDistance, getFireTicks, getHeight, getLastDamageCause, getLocation, getLocation, getMaxFireTicks, getNearbyEntities, getOrigin, getPassenger, getPassengers, getPistonMoveReaction, getPortalCooldown, getScoreboardTags, getServer, getTicksLived, getType, getUniqueId, getVehicle, getVelocity, getWidth, getWorld, hasGravity, isCustomNameVisible, isDead, isEmpty, isGlowing, isInsideVehicle, isInvulnerable, isOnGround, isSilent, isValid, leaveVehicle, playEffect, remove, removePassenger, removeScoreboardTag, setCustomNameVisible, setFallDistance, setFireTicks, setGlowing, setGravity, setInvulnerable, setLastDamageCause, setPassenger, setPortalCooldown, setSilent, setTicksLived, setVelocity, spigot, teleport, teleport, teleport, teleport
addPotionEffect, addPotionEffect, addPotionEffects, getActiveItem, getActivePotionEffects, getArrowsStuck, getCanPickupItems, getEquipment, getEyeHeight, getEyeHeight, getEyeLocation, getHandRaisedTime, getItemUseRemainingTime, getKiller, getLastDamage, getLastTwoTargetBlocks, getLeashHolder, getLineOfSight, getMaximumAir, getMaximumNoDamageTicks, getNoDamageTicks, getPotionEffect, getRemainingAir, getRemoveWhenFarAway, getShieldBlockingDelay, getTargetBlock, hasAI, hasLineOfSight, hasPotionEffect, isCollidable, isGliding, isHandRaised, isLeashed, removePotionEffect, setAI, setArrowsStuck, setCanPickupItems, setCollidable, setGliding, setKiller, setLastDamage, setLeashHolder, setMaximumAir, setMaximumNoDamageTicks, setNoDamageTicks, setRemainingAir, setRemoveWhenFarAway, setShieldBlockingDelay
getMetadata, hasMetadata, removeMetadata, setMetadata
getCustomName, setCustomName
addAttachment, addAttachment, addAttachment, addAttachment, getEffectivePermissions, hasPermission, hasPermission, isPermissionSet, isPermissionSet, recalculatePermissions, removeAttachment
launchProjectile, launchProjectile
getTarget, setTarget
isOp, setOp
void rangedAttack(LivingEntity target, float charge)
target
- the entity to targetcharge
- How "charged" the attack is (how far back the bow was pulled for Bow attacks).
This should be a value between 0 and 1, represented as targetDistance/maxDistance.void setChargingAttack(boolean raiseHands)
raiseHands
- Whether the entities hands are raised to charge attackdefault boolean isChargingAttack()
LivingEntity.isHandRaised()
, if the entity is charging an attackCopyright © 2019. All rights reserved.