public class ClientPlayerEntity extends AbstractClientPlayerEntity
PlayerEntity.SleepResultEntity.IMoveCallbackrotateElytraX, rotateElytraY, rotateElytraZ, worldClientabilities, cameraYaw, chasingPosX, chasingPosY, chasingPosZ, container, enterChestInventory, experience, experienceLevel, experienceTotal, eyesInWaterPlayer, fishingBobber, flyToggleTimer, foodStats, inventory, LEFT_SHOULDER_ENTITY, MAIN_HAND, openContainer, PERSISTED_NBT_TAG, PLAYER_MODEL_FLAG, prevCameraYaw, prevChasingPosX, prevChasingPosY, prevChasingPosZ, REACH_DISTANCE, RIGHT_SHOULDER_ENTITY, spawnForced, spawnForcedMap, spawnPos, spawnPosMap, speedInAir, STANDING_SIZE, xpCooldown, xpSeedactiveItemStack, activeItemStackUseCount, arrowHitTimer, attackedAtYaw, attackingPlayer, beeStingRemovalCooldown, brain, dead, deathTime, ENTITY_GRAVITY, hurtTime, idleTime, interpTargetHeadYaw, interpTargetPitch, interpTargetX, interpTargetY, interpTargetYaw, interpTargetZ, interpTicksHead, isJumping, isSwingInProgress, jumpMovementFactor, lastDamage, limbSwing, limbSwingAmount, LIVING_FLAGS, maxHurtResistantTime, maxHurtTime, movedDistance, moveForward, moveStrafing, moveVertical, NAMETAG_DISTANCE, newPosRotationIncrements, onGroundSpeedFactor, prevLimbSwingAmount, prevMovedDistance, prevOnGroundSpeedFactor, prevRenderYawOffset, prevRotationYawHead, prevSwingProgress, randomUnused1, randomUnused2, recentlyHit, renderYawOffset, rotationYawHead, scoreValue, SLEEPING_SIZE, spinAttackDuration, SWIM_SPEED, swingingHand, swingProgress, swingProgressInt, ticksElytraFlying, ticksSinceLastSwing, unused180addedToChunk, cachedUniqueIdString, chunkCoordX, chunkCoordY, chunkCoordZ, collided, collidedHorizontally, collidedVertically, dataManager, dimension, distanceWalkedModified, distanceWalkedOnStepModified, entityCollisionReduction, entityUniqueID, eyesInWater, fallDistance, firstUpdate, FLAGS, forceSpawn, glowing, hurtResistantTime, ignoreFrustumCheck, inLava, inPortal, inWater, isAirBorne, lastPortalPos, lastPortalVec, lastTickPosX, lastTickPosY, lastTickPosZ, LOGGER, motionMultiplier, noClip, onGround, portalCounter, POSE, prevDistanceWalkedModified, preventEntitySpawning, prevPosX, prevPosY, prevPosZ, prevRotationPitch, prevRotationYaw, rand, removed, rideCooldown, rotationPitch, rotationYaw, serverPosX, serverPosY, serverPosZ, stepHeight, submergedHeight, teleportDirection, ticksExisted, timeUntilPortal, velocityChanged, worldDUMMY| Constructor and Description |
|---|
ClientPlayerEntity(Minecraft minecraftIn,
ClientWorld clientWorldIn,
ClientPlayNetHandler connectionIn,
StatisticsManager statsManager,
ClientRecipeBook recipes) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
attackEntityFrom(DamageSource source,
float amount) |
boolean |
canSwim() |
void |
closeScreen() |
void |
closeScreenAndDropStack() |
protected void |
damageEntity(DamageSource damageSrc,
float damageAmount) |
boolean |
drop(boolean p_225609_1_) |
private void |
func_213839_ed() |
private boolean |
func_223110_ee() |
boolean |
func_228354_I_() |
private boolean |
func_228356_eG_() |
private boolean |
func_228357_eH_() |
Hand |
getActiveHand() |
float |
getHorseJumpPower() |
protected int |
getPermissionLevel() |
float |
getPitch(float partialTicks) |
ClientRecipeBook |
getRecipeBook() |
java.lang.String |
getServerBrand() |
StatisticsManager |
getStats() |
float |
getWaterBrightness() |
float |
getYaw(float partialTicks) |
void |
handleStatusUpdate(byte id) |
void |
heal(float healAmount) |
boolean |
isAutoJumpEnabled() |
boolean |
isCrouching() |
protected boolean |
isCurrentViewEntity() |
boolean |
isGlowing() |
boolean |
isHandActive() |
boolean |
isRidingHorse() |
boolean |
isRowingBoat() |
boolean |
isServerWorld() |
boolean |
isShowDeathScreen() |
boolean |
isSneaking() |
boolean |
isUser() |
void |
livingTick() |
void |
move(MoverType typeIn,
Vec3d pos) |
void |
notifyDataManagerChange(DataParameter<?> key) |
void |
onCriticalHit(Entity entityHit) |
void |
onEnchantmentCritical(Entity entityHit) |
private void |
onUpdateWalkingPlayer() |
void |
openBook(ItemStack stack,
Hand hand) |
void |
openCommandBlock(CommandBlockTileEntity commandBlock) |
void |
openJigsaw(JigsawTileEntity p_213826_1_) |
void |
openMinecartCommandBlock(CommandBlockLogic commandBlock) |
void |
openSignEditor(SignTileEntity signTile) |
void |
openStructureBlock(StructureBlockTileEntity structure) |
void |
playSound(SoundEvent soundIn,
float volume,
float pitch) |
void |
playSound(SoundEvent p_213823_1_,
SoundCategory p_213823_2_,
float p_213823_3_,
float p_213823_4_) |
protected void |
pushOutOfBlocks(double x,
double y,
double z) |
EffectInstance |
removeActivePotionEffect(Effect potioneffectin) |
void |
removeRecipeHighlight(IRecipe<?> p_193103_1_) |
void |
resetActiveHand() |
void |
respawnPlayer() |
void |
sendChatMessage(java.lang.String message) |
void |
sendHorseInventory() |
protected void |
sendHorseJump() |
void |
sendMessage(ITextComponent component) |
void |
sendPlayerAbilities() |
void |
sendStatusMessage(ITextComponent chatComponent,
boolean actionBar) |
void |
setActiveHand(Hand hand) |
void |
setPermissionLevel(int p_184839_1_) |
void |
setPlayerSPHealth(float health) |
void |
setServerBrand(java.lang.String brand) |
void |
setShowDeathScreen(boolean p_228355_1_) |
void |
setSprinting(boolean sprinting) |
void |
setXPStats(float currentXP,
int maxXP,
int level) |
private boolean |
shouldBlockPushPlayer(BlockPos p_205027_1_) |
boolean |
startRiding(Entity entityIn,
boolean force) |
void |
stopRiding() |
void |
swingArm(Hand hand) |
void |
tick() |
protected void |
updateAutoJump(float p_189810_1_,
float p_189810_2_) |
void |
updateEntityActionState() |
protected boolean |
updateEyesInWaterPlayer() |
void |
updateRidden() |
void |
updateSyncFields(ClientPlayerEntity old) |
getDownloadImageSkin, getFovModifier, getLocationCape, getLocationElytra, getLocationSkin, getLocationSkin, getPlayerInfo, getSkinType, hasPlayerInfo, hasSkin, isCreative, isPlayerInfoSet, isSpectatoraddExhaustion, addExperienceLevel, addItemStackToInventory, addMovementStat, addScore, addShoulderEntity, addStat, addStat, addStat, addStat, attackTargetEntityWithCurrentItem, blockActionRestricted, blockUsingShield, canAttackPlayer, canEat, canHarvestBlock, canPickUpItem, canPlayerEdit, canTriggerWalking, canUseCommandBlock, checkBedValidRespawnPosition, createCooldownTracker, damageArmor, damageShield, destroyVanishingCursedItems, disableShield, doWaterSplashEffect, dropInventory, dropItem, dropItem, findAmmo, getAbsorptionAmount, getAIMoveSpeed, getAlwaysRenderNameTagForRender, getArmorInventoryList, getBedLocation, getBedLocation, getCapability, getCooldownPeriod, getCooldownTracker, getCooledAttackStrength, getDeathSound, getDigSpeed, getDigSpeed, getDisplayName, getDisplayNameAndUUID, getExperiencePoints, getFallSound, getFireImmuneTicks, getFoodStats, getGameProfile, getHeldEquipment, getHighspeedSplashSound, getHurtSound, getInventoryEnderChest, getItemStackFromSlot, getLeftShoulderEntity, getLuck, getMaxInPortalTime, getName, getOfflineUUID, getPortalCooldown, getPrefixes, getPrimaryHand, getRightShoulderEntity, getScore, getScoreboardName, getSize, getSleepTimer, getSoundCategory, getSpawnDimension, getSpeedFactor, getSplashSound, getStandingEyeHeight, getSuffixes, getSwimSound, getUUID, getWorldScoreboard, getXPSeed, getYOffset, giveExperiencePoints, hasReducedDebug, interactOn, isAllowEdit, isInvulnerableTo, isMovementBlocked, isNormalCube, isPlayer, isPlayerFullyAsleep, isPushedByWater, isSecondaryUseActive, isSpawnForced, isSpawnForced, isStayingOnGroundSurface, isSwimming, isWearing, jump, maybeBackOffFromEdge, onDeath, onEnchant, onFoodEaten, onKillEntity, onLivingFall, openContainer, openHorseInventory, openMerchantContainer, preparePlayerToSpawn, readAdditional, refreshDisplayName, registerAttributes, registerData, remove, replaceItemInInventory, resetCooldown, resetRecipes, setAbsorptionAmount, setGameType, setItemStackToSlot, setLeftShoulderEntity, setMotionMultiplier, setPrimaryHand, setReducedDebug, setRespawnPosition, setRightShoulderEntity, setScore, setSpawnDimenion, setSpawnPoint, shouldHeal, spawnShoulderEntities, spawnSweepParticles, spinAttack, startFallFlying, startSleeping, stopFallFlying, stopSleepInBed, takeStat, travel, trySleep, tryToStartFallFlying, unlockRecipes, unlockRecipes, updatePose, updateSwimming, wakeUp, wantsToStopRiding, writeAdditional, xpBarCapaddPotionEffect, applyArmorCalculations, applyEntityCollision, applyPotionDamageCalculations, areAllPotionsAmbient, attackable, attackEntityAsMob, attemptTeleport, baseTick, calculateFallDamage, canAttack, canAttack, canAttack, canBeCollidedWith, canBeHitWithPotion, canBePushed, canBeRiddenInWater, canBreatheUnderwater, canDropLoot, canEntityBeSeen, clearActivePotions, clearBedPosition, collideWithEntity, collideWithNearbyEntities, constructKnockBackVector, createBrain, createSpawnPacket, createWitherRose, curePotionEffects, decreaseAirSupply, determineNextAir, dropExperience, dropLoot, dropSpecialItems, frostWalk, getActiveItemStack, getActivePotionEffect, getActivePotionEffects, getActivePotionMap, getArmorCoverPercentage, getArrowCountInEntity, getAttackingEntity, getAttribute, getAttributes, getBedDirection, getBedPosition, getBeeStingCount, getBlockState, getBrain, getCombatTracker, getCreatureAttribute, getDrinkSound, getEatSound, getEyeHeight, getHealth, getHeldItem, getHeldItemMainhand, getHeldItemOffhand, getIdleTime, getItemInUseCount, getItemInUseMaxCount, getJumpUpwardsMotion, getLastAttackedEntity, getLastAttackedEntityTime, getLastDamageSource, getLootContextBuilder, getLootTableResourceLocation, getMaxHealth, getRenderScale, getRevengeTarget, getRevengeTimer, getRNG, getRotationYawHead, getSoundPitch, getSoundVolume, getSwimAnimation, getSwingProgress, getTicksElytraFlying, getTotalArmorValue, getVisibilityMultiplier, getWaterSlowDown, handleFluidJump, handleFluidSneak, hasItemInSlot, isActiveItemStackBlocking, isActualySwimming, isAlive, isChild, isElytraFlying, isEntityInsideOpaqueBlock, isEntityUndead, isOnLadder, isPotionActive, isPotionApplicable, isSleeping, isSpinAttacking, isSuppressingSlidingDownLadder, knockBack, lookAt, markPotionsDirty, markVelocityChanged, onChangedPotionEffect, onDeathUpdate, onFinishedPotionEffect, onItemPickup, onItemUseFinish, onKillCommand, onNewPotionEffect, outOfWorld, performHurtAnimation, playEquipSound, playFallSound, playHurtSound, removePotionEffect, resetPotionEffectMetadata, sendBreakAnimation, sendBreakAnimation, sendEndCombat, sendEnterCombat, setAIMoveSpeed, setArrowCountInEntity, setBedPosition, setBeeStingCount, setHeadRotation, setHealth, setHeldItem, setIdleTime, setJumping, setLastAttackedEntity, setLivingFlag, setPartying, setPositionAndRotationDirect, setRenderYawOffset, setRevengeTarget, setRotationYawHead, shouldRiderFaceForward, spawnDrops, startSpinAttack, stopActiveHand, swing, triggerItemUseEffects, updateArmSwingProgress, updateDistance, updateFallState, updatePotionEffects, updatePotionMetadata, updateSpinAttackaddPassenger, addTag, addTrackingPlayer, addVelocity, allowLogging, applyEnchantments, applyOrientationToEntity, applyPlayerInteraction, areEyesInFluid, areEyesInFluid, awardKillScore, calculateUpVector, canBeAttackedWithItem, canBeRidden, canExplosionDestroyBlock, canFitPassenger, canPassengerSteer, canRenderOnFire, canTrample, canUpdate, canUpdate, captureDrops, captureDrops, changeDimension, changeDimension, checkDespawn, collideBoundingBox, collideBoundingBoxHeuristically, copyDataFromOld, copyLocationAndAnglesFrom, createRunningParticles, dealFireDamage, decrementTimeUntilPortal, detach, determineNextStepDistance, doBlockCollisions, doesEntityNotTriggerPressurePlate, entityDropItem, entityDropItem, entityDropItem, entityDropItem, equals, extinguish, fillCrashReport, forceSetPosition, getAdjustedHorizontalFacing, getAir, getAllowedMovement, getBoundingBox, getBoundingBox, getBrightness, getCachedUniqueIdString, getCollisionBorderSize, getCollisionBoundingBox, getCollisionBox, getCommandSource, getControllingPassenger, getCustomName, getDataManager, getDistance, getDistanceSq, getDistanceSq, getDistanceSq, getEntityId, getEntityString, getEntityWorld, getEquipmentAndArmor, getExplosionResistance, getEyeHeight, getEyeHeight, getEyePosition, getFireTimer, getFlag, getForward, getHeight, getHorizontalFacing, getHoverEvent, getJumpFactor, getLastPortalVec, getLook, getLookVec, getLowestRidingEntity, getMaxAir, getMaxFallHeight, getMirroredYaw, getMotion, getMountedYOffset, getOnPosition, getPassengers, getPersistentData, getPitchYaw, getPose, getPosition, getPositionUnderneath, getPositionVec, getPositionVector, getPosX, getPosXRandom, getPosXWidth, getPosY, getPosYEye, getPosYHeight, getPosYRandom, getPosZ, getPosZRandom, getPosZWidth, getProfessionName, getPushReaction, getRecursivePassengers, getRenderBoundingBox, getRenderDistanceWeight, getRidingEntity, getRotatedYaw, getSelfAndPassengers, getServer, getSubmergedHeight, getTags, getTeam, getTeamColor, getTeleportDirection, getType, getUniqueID, getUpVector, getVectorForRotation, getWidth, handleFluidAcceleration, handlePistonMovement, handleWaterMovement, hasCustomName, hashCode, hasNoGravity, hasPermissionLevel, hitByEntity, horizontalMag, ignoreItemEntityData, isAddedToWorld, isBeingRidden, isBurning, isCustomNameVisible, isDescending, isDiscrete, isEntityEqual, isImmuneToExplosions, isImmuneToFire, isInLava, isInRangeToRender3d, isInRangeToRenderDist, isInvisible, isInvisibleToPlayer, isInvulnerable, isInWater, isInWaterOrBubbleColumn, isInWaterRainOrBubbleColumn, isLiving, isNonBoss, isOffsetPositionInLiquid, isOnePlayerRiding, isOnSameTeam, isOnScoreboardTeam, isPassenger, isPassenger, isPassenger, isPoseClear, isRidingOrBeingRiddenBy, isRidingSameEntity, isSilent, isSpectatedByPlayer, isSprinting, isSteppingCarefully, isSuppressingBounce, isVisuallySwimming, isWet, makeFlySound, moveForced, moveRelative, moveToBlockPosAndAngles, newDoubleNBTList, newFloatNBTList, onAddedToWorld, onCollideWithPlayer, onEnterBubbleColumn, onEnterBubbleColumnWithAirAbove, onInsideBlock, onRemovedFromWorld, onStruckByLightning, pick, playFlySound, playStepSound, playSwimSound, positionRider, processInitialInteract, read, recalculateSize, recenterBoundingBox, remove, removePassenger, removePassengers, removeTag, removeTrackingPlayer, repositionDirectPassengers, resetPositionToBB, revive, rotateTowards, setAir, setBoundingBox, setCustomName, setCustomNameVisible, setEntityId, setFire, setFireTimer, setFlag, setGlowing, setInLava, setInvisible, setInvulnerable, setLocationAndAngles, setMotion, setMotion, setNoGravity, setOnFireFromLava, setPacketCoordinates, setPortal, setPose, setPosition, setPositionAndRotation, setPositionAndUpdate, setPositionNonDirty, setRawPosition, setRenderDistanceWeight, setRotation, setSilent, setSneaking, setSwimming, setUniqueId, setVelocity, setWorld, shouldReceiveErrors, shouldReceiveFeedback, shouldSetPosAfterLoading, spawnRunningParticles, startRiding, teleportKeepLoaded, toString, updatePassenger, updatePortal, writeUnlessPassenger, writeUnlessRemoved, writeWithoutTypeIdareCapsCompatible, areCapsCompatible, deserializeCaps, gatherCapabilities, gatherCapabilities, getCapabilities, invalidateCaps, reviveCaps, serializeCapsclone, finalize, getClass, notify, notifyAll, wait, wait, waitcanBeRiddenInWater, canRiderInteract, deserializeNBT, getClassification, getEntity, getPickedResult, serializeNBT, shouldRiderSitgetCapabilitypublic final ClientPlayNetHandler connection
private final StatisticsManager stats
private final ClientRecipeBook recipeBook
private final java.util.List<IAmbientSoundHandler> ambientSoundHandlers
private int permissionLevel
private double lastReportedPosX
private double lastReportedPosY
private double lastReportedPosZ
private float lastReportedYaw
private float lastReportedPitch
private boolean prevOnGround
private boolean field_228351_cj_
private boolean serverSprintState
private int positionUpdateTicks
private boolean hasValidHealth
private java.lang.String serverBrand
public MovementInput movementInput
protected final Minecraft mc
protected int sprintToggleTimer
public int sprintingTicksLeft
public float renderArmYaw
public float renderArmPitch
public float prevRenderArmYaw
public float prevRenderArmPitch
private int horseJumpPowerCounter
private float horseJumpPower
public float timeInPortal
public float prevTimeInPortal
private boolean handActive
private Hand activeHand
private boolean rowingBoat
private boolean autoJumpEnabled
private int autoJumpTime
private boolean wasFallFlying
private int counterInWater
private boolean showDeathScreen
public ClientPlayerEntity(Minecraft minecraftIn, ClientWorld clientWorldIn, ClientPlayNetHandler connectionIn, StatisticsManager statsManager, ClientRecipeBook recipes)
public boolean attackEntityFrom(DamageSource source, float amount)
attackEntityFrom in class PlayerEntitypublic void heal(float healAmount)
heal in class LivingEntitypublic boolean startRiding(Entity entityIn, boolean force)
startRiding in class Entitypublic void stopRiding()
stopRiding in class PlayerEntitypublic float getYaw(float partialTicks)
getYaw in class LivingEntitypublic void tick()
tick in class PlayerEntityprivate void onUpdateWalkingPlayer()
public boolean drop(boolean p_225609_1_)
drop in class PlayerEntitypublic void sendChatMessage(java.lang.String message)
public void swingArm(Hand hand)
swingArm in class LivingEntitypublic void respawnPlayer()
respawnPlayer in class PlayerEntityprotected void damageEntity(DamageSource damageSrc, float damageAmount)
damageEntity in class PlayerEntitypublic void closeScreen()
closeScreen in class PlayerEntitypublic void closeScreenAndDropStack()
public void setPlayerSPHealth(float health)
public void sendPlayerAbilities()
sendPlayerAbilities in class PlayerEntitypublic boolean isUser()
isUser in class PlayerEntityprotected void sendHorseJump()
public void sendHorseInventory()
public void setServerBrand(java.lang.String brand)
public java.lang.String getServerBrand()
public StatisticsManager getStats()
public ClientRecipeBook getRecipeBook()
public void removeRecipeHighlight(IRecipe<?> p_193103_1_)
protected int getPermissionLevel()
getPermissionLevel in class Entitypublic void setPermissionLevel(int p_184839_1_)
public void sendStatusMessage(ITextComponent chatComponent, boolean actionBar)
sendStatusMessage in class PlayerEntityprotected void pushOutOfBlocks(double x,
double y,
double z)
pushOutOfBlocks in class Entityprivate boolean shouldBlockPushPlayer(BlockPos p_205027_1_)
public void setSprinting(boolean sprinting)
setSprinting in class LivingEntitypublic void setXPStats(float currentXP,
int maxXP,
int level)
public void sendMessage(ITextComponent component)
sendMessage in interface ICommandSourcesendMessage in class Entitypublic void handleStatusUpdate(byte id)
handleStatusUpdate in class PlayerEntitypublic void setShowDeathScreen(boolean p_228355_1_)
public boolean isShowDeathScreen()
public void playSound(SoundEvent soundIn, float volume, float pitch)
playSound in class PlayerEntitypublic void playSound(SoundEvent p_213823_1_, SoundCategory p_213823_2_, float p_213823_3_, float p_213823_4_)
playSound in class PlayerEntitypublic boolean isServerWorld()
isServerWorld in class LivingEntitypublic void setActiveHand(Hand hand)
setActiveHand in class LivingEntitypublic boolean isHandActive()
isHandActive in class LivingEntitypublic void resetActiveHand()
resetActiveHand in class LivingEntitypublic Hand getActiveHand()
getActiveHand in class LivingEntitypublic void notifyDataManagerChange(DataParameter<?> key)
notifyDataManagerChange in class LivingEntitypublic boolean isRidingHorse()
public float getHorseJumpPower()
public void openSignEditor(SignTileEntity signTile)
openSignEditor in class PlayerEntitypublic void openMinecartCommandBlock(CommandBlockLogic commandBlock)
openMinecartCommandBlock in class PlayerEntitypublic void openCommandBlock(CommandBlockTileEntity commandBlock)
openCommandBlock in class PlayerEntitypublic void openStructureBlock(StructureBlockTileEntity structure)
openStructureBlock in class PlayerEntitypublic void openJigsaw(JigsawTileEntity p_213826_1_)
openJigsaw in class PlayerEntitypublic void openBook(ItemStack stack, Hand hand)
openBook in class PlayerEntitypublic void onCriticalHit(Entity entityHit)
onCriticalHit in class PlayerEntitypublic void onEnchantmentCritical(Entity entityHit)
onEnchantmentCritical in class PlayerEntitypublic boolean isSneaking()
isSneaking in class Entitypublic boolean isCrouching()
isCrouching in class Entitypublic boolean func_228354_I_()
public void updateEntityActionState()
updateEntityActionState in class PlayerEntityprotected boolean isCurrentViewEntity()
public void livingTick()
livingTick in class PlayerEntityprivate void func_213839_ed()
public void updateRidden()
updateRidden in class PlayerEntitypublic boolean isRowingBoat()
@Nullable public EffectInstance removeActivePotionEffect(@Nullable Effect potioneffectin)
removeActivePotionEffect in class LivingEntitypublic boolean isAutoJumpEnabled()
protected void updateAutoJump(float p_189810_1_,
float p_189810_2_)
private boolean func_228356_eG_()
private boolean func_228357_eH_()
private boolean func_223110_ee()
public float getWaterBrightness()
protected boolean updateEyesInWaterPlayer()
updateEyesInWaterPlayer in class PlayerEntitypublic void updateSyncFields(ClientPlayerEntity old)