public class HookEntity
extends net.minecraft.entity.projectile.FishingBobberEntity
implements net.minecraftforge.fml.common.registry.IEntityAdditionalSpawnData
| Modifier and Type | Class and Description |
|---|---|
static class |
HookEntity.HookState
State of a hook.
|
| Modifier and Type | Field and Description |
|---|---|
static net.minecraft.network.datasync.DataParameter<java.lang.Integer> |
DATA_HOOK_STATE |
DATA_HOOKED_ENTITY, hookedIn, life, nibbleblocksBuilding, boardingCooldown, DATA_POSE, DATA_SHARED_FLAGS_ID, ENTITY_COUNTER, entityData, fallDistance, firstTick, fluidHeight, fluidOnEyes, forcedLoading, glowing, hasImpulse, horizontalCollision, hurtMarked, inChunk, invulnerableTime, isInsidePortal, level, LOGGER, maxUpStep, moveDist, noCulling, noPhysics, onGround, portalEntrancePos, portalTime, pushthrough, random, removed, stringUUID, stuckSpeedMultiplier, tickCount, type, uuid, verticalCollision, walkDist, walkDistO, wasEyeInWater, wasTouchingWater, xChunk, xo, xOld, xRot, xRotO, yChunk, yo, yOld, yRot, yRotO, zChunk, zo, zOld| Constructor and Description |
|---|
HookEntity(net.minecraft.world.World world,
net.minecraft.entity.player.PlayerEntity player,
double x,
double y,
double z)
Initializes the hook with a position.
|
HookEntity(net.minecraft.world.World world,
net.minecraft.entity.player.PlayerEntity player,
EnumRodType rodType,
int rodQuality)
Initializes the hook from a source rod.
|
| Modifier and Type | Method and Description |
|---|---|
SpawnLocation |
createSpawnLocation() |
protected void |
defineSynchedData() |
net.minecraft.network.IPacket<?> |
getAddEntityPacket() |
int |
getDotsShowing() |
EnumRodType |
getRodType() |
net.minecraft.entity.EntityType<?> |
getType() |
void |
init(net.minecraft.entity.player.PlayerEntity player) |
void |
readSpawnData(net.minecraft.network.PacketBuffer additionalData) |
int |
retrieve(net.minecraft.item.ItemStack p_146034_1_) |
void |
setAngler(net.minecraft.entity.Entity entity) |
void |
setNewTimeToCatch() |
void |
shoot(double p_70186_1_,
double p_70186_3_,
double p_70186_5_,
float p_70186_7_,
float p_70186_8_) |
boolean |
shouldStopFishing() |
void |
tick() |
void |
updateRotation() |
void |
writeSpawnData(net.minecraft.network.PacketBuffer buffer) |
addAdditionalSaveData, bringInHookedEntity, canChangeDimensions, canHitEntity, getHookedIn, getPlayerOwner, handleEntityEvent, isMovementNoisy, isOpenWaterFishing, lerpTo, onHitBlock, onHitEntity, onSyncedDataUpdated, readAdditionalSaveData, remove, shouldRenderAtSqrDistancegetOwner, lerpMotion, lerpRotation, onHit, setOwner, shootFromRotationabsMoveTo, absMoveTo, acceptsFailure, acceptsSuccess, addPassenger, addTag, animateHurt, awardKillScore, baseTick, blockPosition, broadcastToPlayer, calculateUpVector, calculateViewVector, canAddPassenger, canBeCollidedWith, canCollideWith, canEnterPose, canRide, canSpawnSprintParticle, canTrample, canUpdate, canUpdate, captureDrops, captureDrops, causeFallDamage, changeDimension, changeDimension, checkAndResetForcedChunkAdditionFlag, checkAndResetUpdateChunkPos, checkDespawn, checkFallDamage, checkInsideBlocks, clearFire, closerThan, collideBoundingBox, collideBoundingBoxHeuristically, collideBoundingBoxLegacy, copyPosition, createCommandSourceStack, createHoverEvent, displayFireAnimation, distanceTo, distanceToSqr, distanceToSqr, distanceToSqr, doEnchantDamageEffects, doWaterSplashEffect, ejectPassengers, equals, fillCrashReportCategory, findDimensionEntryPoint, fireImmune, getAirSupply, getAllSlots, getArmorSlots, getBbHeight, getBbWidth, getBlockExplosionResistance, getBlockJumpFactor, getBlockPosBelowThatAffectsMyMovement, getBlockSpeedFactor, getBlockStateOn, getBoundingBox, getBoundingBoxForCulling, getBoundingBoxForPose, getBrightness, getCollisionHorizontalEscapeVector, getCommandSenderWorld, getControllingPassenger, getCustomName, getDeltaMovement, getDimensionChangingDelay, getDimensions, getDirection, getDismountLocationForPassenger, getDisplayName, getEncodeId, getEntityData, getExitPortal, getEyeHeight, getEyeHeight, getEyeHeight, getEyeHeightAccess, getEyePosition, getEyeY, getFireImmuneTicks, getFluidHeight, getFluidJumpThreshold, getForward, getHandSlots, getHorizontalDistanceSqr, getId, getIndirectPassengers, getLeashOffset, getLightProbePosition, getLookAngle, getMaxAirSupply, getMaxFallDistance, getMotionDirection, getMyRidingOffset, getName, getOnPos, getPacketCoordinates, getPassengers, getPassengersRidingOffset, getPermissionLevel, getPersistentData, getPickRadius, getPistonPushReaction, getPortalWaitTime, getPose, getPosition, getRandomX, getRandomY, getRandomZ, getRelativePortalPosition, getRemainingFireTicks, getRootVehicle, getRopeHoldPosition, getRotationVector, getScoreboardName, getSelfAndPassengers, getServer, getSharedFlag, getSoundSource, getStringUUID, getSwimHighSpeedSplashSound, getSwimSound, getSwimSplashSound, getTags, getTeam, getTeamColor, getTypeName, getUpVector, getUUID, getVehicle, getViewScale, getViewVector, getViewXRot, getViewYRot, getX, getX, getY, getY, getYHeadRot, getZ, getZ, handleInsidePortal, handleNetherPortal, hasCustomName, hashCode, hasIndirectPassenger, hasOnePlayerPassenger, hasPassenger, hasPassenger, hasPermissions, hurt, ignoreExplosion, interact, interactAt, is, isAddedToWorld, isAlive, isAlliedTo, isAlliedTo, isAttackable, isColliding, isControlledByLocalInstance, isCrouching, isCustomNameVisible, isDescending, isDiscrete, isEyeInFluid, isFree, isGlowing, isIgnoringBlockTriggers, isInLava, isInvisible, isInvisibleTo, isInvulnerable, isInvulnerableTo, isInWall, isInWater, isInWaterOrBubble, isInWaterOrRain, isInWaterRainOrBubble, isNoGravity, isOnFire, isOnGround, isOnPortalCooldown, isPassenger, isPassengerOfSameVehicle, isPickable, isPushable, isPushedByFluid, isShiftKeyDown, isSilent, isSpectator, isSprinting, isSteppingCarefully, isSuppressingBounce, isSwimming, isUnderWater, isVehicle, isVisuallyCrawling, isVisuallySwimming, kill, killed, lavaHurt, lerpHeadTo, limitPistonMovement, load, lookAt, makeFlySound, makeStuckInBlock, markHurt, maybeBackOffFromEdge, mirror, move, moveRelative, moveTo, moveTo, moveTo, moveTo, moveTowardsClosestSpace, newDoubleList, newFloatList, nextStep, onAboveBubbleCol, onAddedToWorld, onInsideBlock, onInsideBubbleColumn, onlyOpCanSetNbt, onPassengerTurned, onRemovedFromWorld, outOfWorld, pick, playerTouch, playFlySound, playSound, playStepSound, playSwimSound, position, positionRider, processPortalCooldown, push, push, reapplyPosition, refreshDimensions, remove, removeAfterChangingDimensions, removePassenger, removeTag, removeVehicle, repositionEntityAfterLoad, resetPos, restoreFrom, revive, rideableUnderWater, rideTick, rotate, save, saveAsPassenger, saveWithoutId, sendMessage, setAirSupply, setBoundingBox, setCustomName, setCustomNameVisible, setDeltaMovement, setDeltaMovement, setGlowing, setId, setInvisible, setInvulnerable, setItemSlot, setLevel, setLocationFromBoundingbox, setNoGravity, setOnGround, setPacketCoordinates, setPacketCoordinates, setPortalCooldown, setPos, setPosAndOldPos, setPose, setPosRaw, setRemainingFireTicks, setRot, setSecondsOnFire, setSharedFlag, setShiftKeyDown, setSilent, setSlot, setSprinting, setSwimming, setUUID, setViewScale, setYBodyRot, setYHeadRot, shouldBlockExplode, shouldInformAdmins, shouldRender, shouldShowName, showVehicleHealth, skipAttackInteraction, spawnAtLocation, spawnAtLocation, spawnAtLocation, spawnAtLocation, spawnSprintParticle, startRiding, startRiding, startSeenByPlayer, stopRiding, stopSeenByPlayer, teleportTo, teleportToWithTicket, thunderHit, toString, turn, unRide, updateFluidHeightAndDoFluidPushing, updateInWaterStateAndDoFluidPushing, updateSwimmingareCapsCompatible, areCapsCompatible, deserializeCaps, gatherCapabilities, gatherCapabilities, gatherCapabilities, getCapabilities, getCapability, invalidateCaps, reviveCaps, serializeCapsclone, finalize, getClass, notify, notifyAll, wait, wait, waitpublic static final net.minecraft.network.datasync.DataParameter<java.lang.Integer> DATA_HOOK_STATE
public HookEntity(net.minecraft.world.World world,
net.minecraft.entity.player.PlayerEntity player,
double x,
double y,
double z)
world - The world the hook is in.x - The x coordinate of the hook.y - The y coordinate of the hook.z - The z coordinate of the hook.player - The player who cast the rod.public HookEntity(net.minecraft.world.World world,
net.minecraft.entity.player.PlayerEntity player,
EnumRodType rodType,
int rodQuality)
world - The world the hook is in.player - The player who cast the rod.rodType - The type of rod that was cast.public net.minecraft.entity.EntityType<?> getType()
getType in class net.minecraft.entity.Entityprotected void defineSynchedData()
defineSynchedData in class net.minecraft.entity.projectile.FishingBobberEntitypublic void init(net.minecraft.entity.player.PlayerEntity player)
public void shoot(double p_70186_1_,
double p_70186_3_,
double p_70186_5_,
float p_70186_7_,
float p_70186_8_)
shoot in class net.minecraft.entity.projectile.ProjectileEntitypublic void writeSpawnData(net.minecraft.network.PacketBuffer buffer)
writeSpawnData in interface net.minecraftforge.fml.common.registry.IEntityAdditionalSpawnDatapublic void readSpawnData(net.minecraft.network.PacketBuffer additionalData)
readSpawnData in interface net.minecraftforge.fml.common.registry.IEntityAdditionalSpawnDatapublic void setAngler(net.minecraft.entity.Entity entity)
public void tick()
tick in class net.minecraft.entity.projectile.FishingBobberEntitypublic SpawnLocation createSpawnLocation()
public void setNewTimeToCatch()
public boolean shouldStopFishing()
public void updateRotation()
updateRotation in class net.minecraft.entity.projectile.ProjectileEntitypublic int retrieve(net.minecraft.item.ItemStack p_146034_1_)
retrieve in class net.minecraft.entity.projectile.FishingBobberEntitypublic EnumRodType getRodType()
public int getDotsShowing()
public net.minecraft.network.IPacket<?> getAddEntityPacket()
getAddEntityPacket in class net.minecraft.entity.projectile.FishingBobberEntity