Package org.bukkit.entity
Interface ShulkerBullet
- All Superinterfaces:
Audience
,CommandSender
,Entity
,HoverEventSource<HoverEvent.ShowEntity>
,Metadatable
,Nameable
,Permissible
,PersistentDataHolder
,Pointered
,Projectile
,ServerOperator
,Sound.Emitter
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.bukkit.entity.Entity
Entity.Spigot
-
Method Summary
Modifier and TypeMethodDescriptionGets the current movement direction.int
Gets how many ticks this shulker bullet will attempt to move in its current direction.Retrieve the target of this bullet.Gets the relative offset that this shulker bullet should move towards, note that this will change each tick as the skulker bullet approaches the target.void
setCurrentMovementDirection
(BlockFace movementDirection) Set the current movement direction.void
setFlightSteps
(int steps) Sets how many ticks this shulker bullet will attempt to move in its current direction.void
Sets the target of this bulletvoid
setTargetDelta
(Vector vector) Sets the relative offset that this shulker bullet should move towards, note that this will change each tick as the skulker bullet approaches the target.Methods inherited from interface net.kyori.adventure.audience.Audience
clearTitle, deleteMessage, deleteMessage, filterAudience, forEachAudience, hideBossBar, openBook, openBook, playSound, playSound, playSound, resetTitle, sendActionBar, sendActionBar, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendPlayerListFooter, sendPlayerListFooter, sendPlayerListHeader, sendPlayerListHeader, sendPlayerListHeaderAndFooter, sendPlayerListHeaderAndFooter, sendTitlePart, showBossBar, showTitle, stopSound, stopSound
Methods inherited from interface org.bukkit.command.CommandSender
getName, name, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendPlainMessage, sendRichMessage
Methods inherited from interface org.bukkit.entity.Entity
addPassenger, addScoreboardTag, asHoverEvent, collidesAt, eject, fromMobSpawner, getBoundingBox, getChunk, getEntityId, getEntitySpawnReason, getFacing, getFallDistance, getFireTicks, getFreezeTicks, getHeight, getLastDamageCause, getLocation, getLocation, getMaxFireTicks, getMaxFreezeTicks, getNearbyEntities, getOrigin, getPassenger, getPassengers, getPistonMoveReaction, getPortalCooldown, getPose, getScoreboardTags, getServer, getSpawnCategory, getSwimHighSpeedSplashSound, getSwimSound, getSwimSplashSound, getTicksLived, getTrackedPlayers, getType, getUniqueId, getVehicle, getVelocity, getWidth, getWorld, hasGravity, isCustomNameVisible, isDead, isEmpty, isFreezeTickingLocked, isFrozen, isGlowing, isInBubbleColumn, isInLava, isInPowderedSnow, isInRain, isInsideVehicle, isInvulnerable, isInWater, isInWaterOrBubbleColumn, isInWaterOrRain, isInWaterOrRainOrBubbleColumn, isOnGround, isPersistent, isSilent, isSneaking, isTicking, isUnderWater, isValid, isVisibleByDefault, isVisualFire, leaveVehicle, lockFreezeTicks, playEffect, remove, removePassenger, removeScoreboardTag, setCustomNameVisible, setFallDistance, setFireTicks, setFreezeTicks, setGlowing, setGravity, setInvulnerable, setLastDamageCause, setPassenger, setPersistent, setPortalCooldown, setRotation, setSilent, setSneaking, setTicksLived, setVelocity, setVisibleByDefault, setVisualFire, spawnAt, spawnAt, spigot, teamDisplayName, teleport, teleport, teleport, teleport, teleport, teleport, teleportAsync, teleportAsync, wouldCollideUsing
Methods inherited from interface net.kyori.adventure.text.event.HoverEventSource
asHoverEvent
Methods inherited from interface org.bukkit.metadata.Metadatable
getMetadata, hasMetadata, removeMetadata, setMetadata
Methods inherited from interface org.bukkit.Nameable
customName, customName, getCustomName, setCustomName
Methods inherited from interface org.bukkit.permissions.Permissible
addAttachment, addAttachment, addAttachment, addAttachment, getEffectivePermissions, hasPermission, hasPermission, isPermissionSet, isPermissionSet, permissionValue, permissionValue, recalculatePermissions, removeAttachment
Methods inherited from interface org.bukkit.persistence.PersistentDataHolder
getPersistentDataContainer
Methods inherited from interface net.kyori.adventure.pointer.Pointered
get, getOrDefault, getOrDefaultFrom, pointers
Methods inherited from interface org.bukkit.entity.Projectile
canHitEntity, doesBounce, getOwnerUniqueId, getShooter, hasBeenShot, hasLeftShooter, hitEntity, hitEntity, setBounce, setHasBeenShot, setHasLeftShooter, setShooter
Methods inherited from interface org.bukkit.permissions.ServerOperator
isOp, setOp
-
Method Details
-
getTarget
Retrieve the target of this bullet.- Returns:
- the targeted entity
-
setTarget
Sets the target of this bullet- Parameters:
target
- the entity to target
-
getTargetDelta
Gets the relative offset that this shulker bullet should move towards, note that this will change each tick as the skulker bullet approaches the target.- Returns:
- target delta offset
-
setTargetDelta
Sets the relative offset that this shulker bullet should move towards, note that this will change each tick as the skulker bullet approaches the target. This is usually relative towards their target.- Parameters:
vector
- target
-
getCurrentMovementDirection
Gets the current movement direction. This is used to determine the next movement direction to ensure that the bullet does not move in the same direction.- Returns:
- null or their current direction
-
setCurrentMovementDirection
Set the current movement direction. This is used to determine the next movement direction to ensure that the bullet does not move in the same direction. Set to null to simply pick a random direction.- Parameters:
movementDirection
- null or a direction
-
getFlightSteps
int getFlightSteps()Gets how many ticks this shulker bullet will attempt to move in its current direction.- Returns:
- number of steps
-
setFlightSteps
void setFlightSteps(int steps) Sets how many ticks this shulker bullet will attempt to move in its current direction.- Parameters:
steps
- number of steps
-