Class Player
java.lang.Object
net.minecraftforge.common.capabilities.CapabilityProvider<Entity>
net.minecraft.world.entity.Entity
net.minecraft.world.entity.LivingEntity
net.minecraft.world.entity.player.Player
- All Implemented Interfaces:
CommandSource,EntityAccess,Nameable,ICapabilityProvider,ICapabilityProviderImpl<Entity>,ICapabilitySerializable<CompoundTag>,IForgeEntity,IForgePlayer,INBTSerializable<CompoundTag>
- Direct Known Subclasses:
AbstractClientPlayer,ServerPlayer
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class net.minecraft.world.entity.LivingEntity
LivingEntity.FallsoundsNested classes/interfaces inherited from class net.minecraft.world.entity.Entity
Entity.MoveFunction, Entity.MovementEmission, Entity.RemovalReasonNested classes/interfaces inherited from class net.minecraftforge.common.capabilities.CapabilityProvider
CapabilityProvider.AsField<B extends ICapabilityProviderImpl<B>> -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final Abilitiesfloatprivate final ItemCooldownsstatic final floatprivate static final EntityDataAccessor<Float>protected static final EntityDataAccessor<Byte>protected static final EntityDataAccessor<Byte>private static final EntityDataAccessor<Integer>protected static final EntityDataAccessor<CompoundTag>protected static final EntityDataAccessor<CompoundTag>static final floatprotected final floatprivate Componentprotected intstatic final intprotected PlayerEnderChestContainerintfloatprivate static final intprotected FoodDataprivate Poseprivate final com.mojang.authlib.GameProfileprivate final Inventoryfinal InventoryMenuprotected intprivate ItemStackprivate intstatic final intstatic final intfloatstatic final Stringprivate final LazyOptional<IItemHandler>private final LazyOptional<IItemHandler>private final LazyOptional<IItemHandler>private static final Map<Pose,EntityDimensions> private final Collection<MutableComponent>private booleanstatic final intprivate intstatic final EntityDimensionsprivate final Collection<MutableComponent>static final floatstatic final floatintprivate longintstatic final Stringstatic final intprotected booleandoubledoubledoubledoubledoubledoubleFields inherited from class net.minecraft.world.entity.LivingEntity
animationPosition, animationSpeed, animationSpeedOld, animStep, animStepO, ARMOR_SLOT_OFFSET, ARMOR_SLOTS, attackAnim, attackStrengthTicker, autoSpinAttackTicks, brain, DATA_LIVING_ENTITY_FLAGS, dead, DEATH_DURATION, deathScore, deathTime, DEFAULT_BASE_GRAVITY, EQUIPMENT_SLOT_OFFSET, EXTRA_RENDER_CULLING_SIZE_WITH_BIG_HAT, fallFlyTicks, flyingSpeed, HAND_SLOTS, hurtDir, hurtDuration, hurtTime, invulnerableDuration, jumping, lastHurt, lastHurtByPlayer, lastHurtByPlayerTime, lerpHeadSteps, lerpSteps, lerpX, lerpXRot, lerpY, lerpYRot, lerpZ, LIVING_ENTITY_FLAG_IS_USING, LIVING_ENTITY_FLAG_OFF_HAND, LIVING_ENTITY_FLAG_SPIN_ATTACK, lyHeadRot, MIN_MOVEMENT_DISTANCE, noActionTime, oAttackAnim, oRun, PLAYER_HURT_EXPERIENCE_TIME, removeArrowTime, removeStingerTime, rotA, rotOffs, run, SLEEPING_DIMENSIONS, SWING_DURATION, swinging, swingingArm, swingTime, timeOffs, USE_ITEM_INTERVAL, useItem, useItemRemaining, xxa, yBodyRot, yBodyRotO, yHeadRot, yHeadRotO, yya, zzaFields inherited from class net.minecraft.world.entity.Entity
BASE_TICKS_REQUIRED_TO_FREEZE, blocksBuilding, BOARDING_COOLDOWN, boardingCooldown, BREATHING_DISTANCE_BELOW_EYES, DATA_POSE, DATA_SHARED_FLAGS_ID, DEFAULT_BB_HEIGHT, DEFAULT_BB_WIDTH, DELTA_AFFECTED_BY_BLOCKS_BELOW, ENTITY_COUNTER, entityData, fallDistance, firstTick, FLAG_FALL_FLYING, FLAG_GLOWING, FLAG_ONFIRE, fluidHeight, flyDist, FREEZE_HURT_FREQUENCY, hasImpulse, horizontalCollision, hurtMarked, ID_TAG, invulnerableTime, isInPowderSnow, isInsidePortal, level, MAX_ENTITY_TAG_COUNT, maxUpStep, minorHorizontalCollision, moveDist, noCulling, noPhysics, onGround, PASSENGERS_TAG, portalEntrancePos, portalTime, random, stringUUID, stuckSpeedMultiplier, tickCount, TOTAL_AIR_SUPPLY, uuid, UUID_TAG, verticalCollision, verticalCollisionBelow, walkDist, walkDistO, wasEyeInWater, wasInPowderSnow, wasOnFire, wasTouchingWater, xo, xOld, xRotO, yo, yOld, yRotO, zo, zOldFields inherited from interface net.minecraft.commands.CommandSource
NULL -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidactuallyHurt(DamageSource p_36312_, float p_36313_) voidaddAdditionalSaveData(CompoundTag p_36265_) booleanprivate voidaddParticlesAroundSelf(ParticleOptions p_36209_) voidaiStep()voidintawardRecipes(Collection<Recipe<?>> p_36213_) voidawardRecipesByKey(ResourceLocation[] p_36228_) voidawardStat(ResourceLocation p_36221_) voidawardStat(ResourceLocation p_36223_, int p_36224_) voidvoidbooleanblockActionRestricted(Level p_36188_, BlockPos p_36189_, GameType p_36190_) protected voidblockUsingShield(LivingEntity p_36295_) booleanbooleancanEat(boolean p_36392_) booleancanHarmPlayer(Player p_36169_) booleancanTakeItem(ItemStack p_36315_) booleanbooleancauseFallDamage(float p_150093_, float p_150094_, DamageSource p_150095_) voidcauseFoodExhaustion(float p_36400_) voidcheckMovementStatistics(double p_36379_, double p_36380_, double p_36381_) private voidcheckRidingStatistics(double p_36388_, double p_36389_, double p_36390_) voidstatic AttributeSupplier.Builderprotected ItemCooldownsstatic UUIDcreatePlayerUUID(com.mojang.authlib.GameProfile p_36199_) static UUIDcreatePlayerUUID(String p_36284_) voidprivate MutableComponentdecorateDisplayNameComponent(MutableComponent p_36219_) protected voidprotected voidvoiddie(DamageSource p_36152_) voiddisableShield(boolean p_36385_) voiddisplayClientMessage(Component p_36216_, boolean p_36217_) protected voiddoAutoAttackOnTouch(LivingEntity p_36355_) protected voidprotected voidfindRespawnPositionAndUseSpawnBlock(ServerLevel p_36131_, BlockPos p_36132_, float p_36133_, boolean p_36134_, boolean p_36135_) protected booleanfloatfloatgetAttackStrengthScale(float p_36404_) protected float<T> LazyOptional<T>getCapability(Capability<T> capability, Direction facing) Retrieves the Optional handler for the capability requested on the specific side.floatprotected SoundEventfloatgetDestroySpeed(BlockState p_36282_) Deprecated.floatgetDigSpeed(BlockState p_36282_, BlockPos pos) intgetDimensions(Pose p_36166_) com.google.common.collect.ImmutableList<Pose>intprotected intgetExperienceReward(Player p_36297_) protected intcom.mojang.authlib.GameProfileprotected SoundEventgetHurtSound(DamageSource p_36310_) getItemBySlot(EquipmentSlot p_36257_) floatgetLuck()protected Entity.MovementEmissiondoublegetName()intgetProjectile(ItemStack p_36349_) getRopeHoldPosition(float p_36374_) intgetScore()intgetSlot(int p_150112_) floatgetSpeed()floatgetStandingEyeHeight(Pose p_36259_, EntityDimensions p_36260_) protected SoundEventprotected SoundEventprotected SoundEventintvoidgiveExperienceLevels(int p_36276_) voidgiveExperiencePoints(int p_36291_) voidhandleEntityEvent(byte p_36120_) booleanhasCorrectToolForDrops(BlockState p_36299_) booleanhurt(DamageSource p_36154_, float p_36155_) protected voidhurtArmor(DamageSource p_36251_, float p_36252_) protected voidhurtCurrentlyUsedShield(float p_36383_) protected voidhurtHelmet(DamageSource p_150103_, float p_150104_) voidincreaseScore(int p_36402_) interactOn(Entity p_36158_, InteractionHand p_36159_) private booleanbooleanprotected booleanbooleanabstract booleanbooleanisHurt()protected booleanbooleanisInvulnerableTo(DamageSource p_36249_) booleanbooleanisModelPartShown(PlayerModelPart p_36171_) booleanbooleanbooleanbooleanbooleanabstract booleanprotected booleanbooleanvoidvoidkilled(ServerLevel p_36128_, LivingEntity p_36129_) voidvoidmakeStuckInBlock(BlockState p_36196_, Vec3 p_36197_) protected Vec3maybeBackOffFromEdge(Vec3 p_36201_, MoverType p_36202_) booleanmayBuild()booleanmayUseItemAt(BlockPos p_36205_, Direction p_36206_, ItemStack p_36207_) private voidvoidonEnchantmentPerformed(ItemStack p_36172_, int p_36173_) protected booleanvoidvoidopenCommandBlock(CommandBlockEntity p_36191_) voidopenHorseInventory(AbstractHorse p_36167_, Container p_36168_) voidopenItemGui(ItemStack p_36174_, InteractionHand p_36175_) voidopenJigsawBlock(JigsawBlockEntity p_36192_) openMenu(MenuProvider p_36150_) voidopenMinecartCommandBlock(BaseCommandBlock p_36182_) voidopenStructureBlock(StructureBlockEntity p_36194_) voidopenTextEdit(SignBlockEntity p_36193_) voidplayNotifySound(SoundEvent p_36140_, SoundSource p_36141_, float p_36142_, float p_36143_) private voidplayShoulderEntityAmbientSound(CompoundTag p_36368_) voidplaySound(SoundEvent p_36137_, float p_36138_, float p_36139_) voidreadAdditionalSaveData(CompoundTag p_36215_) voidForce the displayed name to refresh, by firingPlayerEvent.NameFormat, using the real player name as event parameter.voidremove(Entity.RemovalReason p_150097_) protected voidvoidvoidintresetRecipes(Collection<Recipe<?>> p_36263_) voidvoidrespawn()private voidrespawnEntityOnShoulder(CompoundTag p_36371_) voidrideTick()voidsendMerchantOffers(int p_36121_, MerchantOffers p_36122_, int p_36123_, int p_36124_, boolean p_36125_, boolean p_36126_) protected voidvoidsetAbsorptionAmount(float p_36396_) booleansetEntityOnShoulder(CompoundTag p_36361_) voidsetForcedPose(Pose pose) Force a pose for the player.voidsetItemSlot(EquipmentSlot p_36161_, ItemStack p_36162_) voidsetMainArm(HumanoidArm p_36164_) voidsetReducedDebugInfo(boolean p_36394_) voidsetRemainingFireTicks(int p_36353_) voidsetScore(int p_36398_) protected voidsetShoulderEntityLeft(CompoundTag p_36363_) protected voidsetShoulderEntityRight(CompoundTag p_36365_) booleanprotected booleanshouldRemoveSoulSpeed(BlockState p_36262_) booleanvoidstartAutoSpinAttack(int p_204080_) voidcom.mojang.datafixers.util.Either<Player.BedSleepingProblem,Unit> startSleepInBed(BlockPos p_36203_) voidvoidstopSleepInBed(boolean p_36226_, boolean p_36227_) voidvoidvoidtick()private voidvoidbooleanprivate voidprotected booleanprotected voidvoidvoidupdateTutorialInventoryAction(ItemStack p_150098_, ItemStack p_150099_, ClickAction p_150100_) protected booleanMethods inherited from class net.minecraft.world.entity.LivingEntity
addEffect, addEffect, animateHurt, areAllEffectsAmbient, attackable, baseTick, blockedByShield, brainProvider, broadcastBreakEvent, broadcastBreakEvent, calculateEntityAnimation, calculateFallDamage, canAttack, canAttack, canAttackType, canBeAffected, canBeSeenByAnyone, canBreatheUnderwater, canFreeze, canSpawnSoulSpeedParticle, canStandOnFluid, checkAutoSpinAttack, checkFallDamage, clearSleepingPos, completeUsingItem, createLivingAttributes, createLootContext, createWitherRose, curePotionEffects, decreaseAirSupply, doHurtTarget, doPush, dropAllDeathLoot, dropCustomDeathLoot, dropExperience, dropFromLootTable, equipEventAndSound, forceAddEffect, getActiveEffects, getActiveEffectsMap, getAddEntityPacket, getArmorCoverPercentage, getArmorValue, getArrowCount, getAttackAnim, getAttribute, getAttributeBaseValue, getAttributes, getAttributeValue, getBedOrientation, getBoundingBoxForCulling, getBrain, getCombatTracker, getDamageAfterArmorAbsorb, getDamageAfterMagicAbsorb, getDrinkingSound, getEatingSound, getEffect, getEquipmentSlotForItem, getEyeHeight, getFallFlyingTicks, getFluidFallingAdjustedMovement, getHealth, getItemInHand, getJumpBoostPower, getJumpPower, getKillCredit, getLastClimbablePos, getLastDamageSource, getLastHurtByMob, getLastHurtByMobTimestamp, getLastHurtMob, getLastHurtMobTimestamp, getLocalBoundsForPose, getLootTable, getMainHandItem, getMaxHealth, getMobType, getNoActionTime, getOffhandItem, getRandom, getRelativePortalPosition, getScale, getSleepingPos, getSoundVolume, getStingerCount, getSwimAmount, getTicksUsingItem, getUsedItemHand, getUseItem, getUseItemRemainingTicks, getViewYRot, getVisibilityPercent, getVoicePitch, getWaterSlowDown, getYHeadRot, goDownInWater, handleRelativeFrictionAndCalculateMovement, hasEffect, hasItemInSlot, hasLineOfSight, heal, increaseAirSupply, invalidateCaps, isAffectedByPotions, isAlive, isAutoSpinAttack, isBaby, isBlocking, isCurrentlyGlowing, isDamageSourceBlocked, isDeadOrDying, isEffectiveAi, isFallFlying, isHolding, isHolding, isInvertedHealAndHarm, isInWall, isPickable, isPushable, isSensitiveToWater, isSleeping, isSuppressingSlidingDownLadder, isUsingItem, isVisuallySwimming, jumpInLiquid, kill, knockback, lerpHeadTo, lerpTo, lookAt, makeBrain, onChangedBlock, onClimbable, onEffectAdded, onEffectRemoved, onEffectUpdated, onEnterCombat, onItemPickup, onLeaveCombat, onSyncedDataUpdated, outOfWorld, playBlockFallSound, playHurtSound, push, pushEntities, randomTeleport, recreateFromPacket, releaseUsingItem, removeAllEffects, removeEffect, removeEffectNoUpdate, removeEffectParticles, removeFrost, removeSoulSpeed, resetForwardDirectionOfRelativePortalPosition, reviveCaps, rideableUnderWater, setArrowCount, setDiscardFriction, setHealth, setItemInHand, setJumping, setLastHurtByMob, setLastHurtByPlayer, setLastHurtMob, setLivingEntityFlag, setNoActionTime, setOnGround, setRecordPlayingNearby, setSleepingPos, setSpeed, setSprinting, setStingerCount, setYBodyRot, setYHeadRot, shouldDiscardFriction, shouldDropExperience, shouldDropLoot, shouldRiderFaceForward, spawnSoulSpeedParticle, startSleeping, startUsingItem, stopRiding, stopUsingItem, swing, swing, take, tickDeath, tickEffects, tickHeadTurn, triggerItemUseEffects, tryAddFrost, tryAddSoulSpeed, updateEffectVisibility, updateInvisibilityStatus, updateSwingTime, updateUsingItem, verifyEquippedItemMethods inherited from class net.minecraft.world.entity.Entity
absMoveTo, absMoveTo, acceptsFailure, acceptsSuccess, addPassenger, addTag, awardKillScore, blockPosition, broadcastToPlayer, calculateUpVector, calculateViewVector, canAddPassenger, canBeCollidedWith, canChangeDimensions, canCollideWith, canEnterPose, canRide, canSpawnSprintParticle, canTrample, canUpdate, canUpdate, captureDrops, captureDrops, changeDimension, changeDimension, checkDespawn, checkInsideBlocks, checkOutOfWorld, chunkPosition, clearFire, closerThan, collideBoundingBox, copyPosition, createCommandSourceStack, createHoverEvent, discard, dismountTo, displayFireAnimation, distanceTo, distanceToSqr, distanceToSqr, distanceToSqr, doEnchantDamageEffects, ejectPassengers, equals, eyeBlockPosition, fillCrashReportCategory, findDimensionEntryPoint, fireImmune, gameEvent, gameEvent, gameEvent, gameEvent, getAirSupply, getAllSlots, getBbHeight, getBbWidth, getBlockExplosionResistance, getBlockJumpFactor, getBlockPosBelowThatAffectsMyMovement, getBlockStateOn, getBlockX, getBlockY, getBlockZ, getBoundingBox, getBoundingBoxForPose, getBrightness, getCollisionHorizontalEscapeVector, getCommandSenderWorld, getControllingPassenger, getCustomName, getDeltaMovement, getDirection, getDismountLocationForPassenger, getEncodeId, getEntityData, getExitPortal, getEyeHeight, getEyeHeight, getEyeHeightAccess, getEyePosition, getEyePosition, getEyeY, getFeetBlockState, getFirstPassenger, getFluidHeight, getFluidJumpThreshold, getForward, getGameEventListenerRegistrar, getHandHoldingItemAngle, getId, getIndirectPassengers, getLeashOffset, getLevel, getLightProbePosition, getLookAngle, getMaxAirSupply, getMaxFallDistance, getMotionDirection, getOnPos, getPacketCoordinates, getPassengers, getPassengersAndSelf, getPassengersRidingOffset, getPercentFrozen, getPermissionLevel, getPersistentData, getPickRadius, getPickResult, getPistonPushReaction, getPose, getPosition, getRandomX, getRandomY, getRandomZ, getRemainingFireTicks, getRemovalReason, getRootVehicle, getRotationVector, getSelfAndPassengers, getServer, getSharedFlag, getStringUUID, getTags, getTeam, getTeamColor, getTicksFrozen, getTicksRequiredToFreeze, getType, getTypeName, getUpVector, getUUID, getVehicle, getViewScale, getViewVector, getViewXRot, getX, getX, getXRot, getY, getY, getYRot, getZ, getZ, handleInsidePortal, handleNetherPortal, hasCustomName, hasExactlyOnePlayerPassenger, hasGlowingTag, hashCode, hasIndirectPassenger, hasPassenger, hasPassenger, hasPermissions, ignoreExplosion, interact, interactAt, is, isAddedToWorld, isAlliedTo, isAlliedTo, isAttackable, isColliding, isControlledByLocalInstance, isCrouching, isCustomNameVisible, isDescending, isDiscrete, isEyeInFluid, isFlapping, isFree, isFreezing, isFullyFrozen, isHorizontalCollisionMinor, isIgnoringBlockTriggers, isInLava, isInvisible, isInvisibleTo, isInvulnerable, isInWater, isInWaterOrBubble, isInWaterOrRain, isInWaterRainOrBubble, isNoGravity, isOnFire, isOnGround, isOnPortalCooldown, isPassenger, isPassengerOfSameVehicle, isRemoved, isShiftKeyDown, isSilent, isSprinting, isSteppingCarefully, isSuppressingBounce, isUnderWater, isVehicle, isVisuallyCrawling, lavaHurt, lerpMotion, limitPistonMovement, load, makeBoundingBox, markHurt, mayInteract, mirror, move, moveRelative, moveTo, moveTo, moveTo, moveTo, moveTowardsClosestSpace, newDoubleList, newFloatList, nextStep, occludesVibrations, onAboveBubbleCol, onAddedToWorld, onClientRemoval, onFlap, onInsideBlock, onInsideBubbleColumn, onlyOpCanSetNbt, onPassengerTurned, onRemovedFromWorld, pick, playEntityOnFireExtinguishedSound, playerTouch, playStepSound, playSwimSound, position, positionRider, processFlappingMovement, processPortalCooldown, push, reapplyPosition, recreateFromPacket, refreshDimensions, removeAfterChangingDimensions, removePassenger, removeTag, repositionEntityAfterLoad, resetFallDistance, restoreFrom, revive, rotate, save, saveAsPassenger, saveWithoutId, sendMessage, setAirSupply, setBoundingBox, setCustomName, setCustomNameVisible, setDeltaMovement, setDeltaMovement, setGlowingTag, setId, setInvisible, setInvulnerable, setIsInPowderSnow, setLevelCallback, setNoGravity, setOldPosAndRot, setPacketCoordinates, setPacketCoordinates, setPortalCooldown, setPos, setPos, setPose, setPosRaw, setRemoved, setRot, setSecondsOnFire, setSharedFlag, setSharedFlagOnFire, setShiftKeyDown, setSilent, setSwimming, setTicksFrozen, setUUID, setViewScale, setXRot, setYRot, shouldBlockExplode, shouldInformAdmins, shouldRender, shouldRenderAtSqrDistance, showVehicleHealth, skipAttackInteraction, spawnAtLocation, spawnAtLocation, spawnAtLocation, spawnAtLocation, spawnSprintParticle, startRiding, startRiding, startSeenByPlayer, stopSeenByPlayer, teleportTo, teleportToWithTicket, thunderHit, toString, touchingUnloadedChunk, tryCheckInsideBlocks, turn, unRide, unsetRemoved, updateFluidHeightAndDoFluidPushing, updateInWaterStateAndDoFluidPushingMethods inherited from class net.minecraftforge.common.capabilities.CapabilityProvider
areCapsCompatible, areCapsCompatible, deserializeCaps, gatherCapabilities, gatherCapabilities, gatherCapabilities, getCapabilities, serializeCapsMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface net.minecraft.commands.CommandSource
alwaysAcceptsMethods inherited from interface net.minecraftforge.common.capabilities.ICapabilityProvider
getCapabilityMethods inherited from interface net.minecraftforge.common.extensions.IForgeEntity
canBeRiddenInWater, canRiderInteract, deserializeNBT, getClassification, getParts, getPickedResult, getStepHeight, isMultipartEntity, serializeNBT, shouldRiderSitMethods inherited from interface net.minecraftforge.common.extensions.IForgePlayer
canHit, canInteractWith, canInteractWith, getAttackRange, getReachDistance, isCloseEnough
-
Field Details
-
PERSISTED_NBT_TAG
- See Also:
-
UUID_PREFIX_OFFLINE_PLAYER
- See Also:
-
MAX_NAME_LENGTH
public static final int MAX_NAME_LENGTH- See Also:
-
MAX_HEALTH
public static final int MAX_HEALTH- See Also:
-
SLEEP_DURATION
public static final int SLEEP_DURATION- See Also:
-
WAKE_UP_DURATION
public static final int WAKE_UP_DURATION- See Also:
-
ENDER_SLOT_OFFSET
public static final int ENDER_SLOT_OFFSET- See Also:
-
CROUCH_BB_HEIGHT
public static final float CROUCH_BB_HEIGHT- See Also:
-
SWIMMING_BB_WIDTH
public static final float SWIMMING_BB_WIDTH- See Also:
-
SWIMMING_BB_HEIGHT
public static final float SWIMMING_BB_HEIGHT- See Also:
-
DEFAULT_EYE_HEIGHT
public static final float DEFAULT_EYE_HEIGHT- See Also:
-
STANDING_DIMENSIONS
-
POSES
-
FLY_ACHIEVEMENT_SPEED
private static final int FLY_ACHIEVEMENT_SPEED- See Also:
-
DATA_PLAYER_ABSORPTION_ID
-
DATA_SCORE_ID
-
DATA_PLAYER_MODE_CUSTOMISATION
-
DATA_PLAYER_MAIN_HAND
-
DATA_SHOULDER_LEFT
-
DATA_SHOULDER_RIGHT
-
timeEntitySatOnShoulder
private long timeEntitySatOnShoulder -
inventory
-
enderChestInventory
-
inventoryMenu
-
containerMenu
-
foodData
-
jumpTriggerTime
protected int jumpTriggerTime -
oBob
public float oBob -
bob
public float bob -
takeXpDelay
public int takeXpDelay -
xCloakO
public double xCloakO -
yCloakO
public double yCloakO -
zCloakO
public double zCloakO -
xCloak
public double xCloak -
yCloak
public double yCloak -
zCloak
public double zCloak -
sleepCounter
private int sleepCounter -
wasUnderwater
protected boolean wasUnderwater -
abilities
-
experienceLevel
public int experienceLevel -
totalExperience
public int totalExperience -
experienceProgress
public float experienceProgress -
enchantmentSeed
protected int enchantmentSeed -
defaultFlySpeed
protected final float defaultFlySpeed- See Also:
-
lastLevelUpTime
private int lastLevelUpTime -
gameProfile
private final com.mojang.authlib.GameProfile gameProfile -
reducedDebugInfo
private boolean reducedDebugInfo -
lastItemInMainHand
-
cooldowns
-
fishing
-
prefixes
-
suffixes
-
forcedPose
-
displayname
-
playerMainHandler
-
playerEquipmentHandler
-
playerJoinedHandler
-
-
Constructor Details
-
Player
-
-
Method Details
-
blockActionRestricted
-
createAttributes
-
defineSynchedData
protected void defineSynchedData()- Overrides:
defineSynchedDatain classLivingEntity
-
tick
public void tick()- Overrides:
tickin classLivingEntity
-
isSecondaryUseActive
public boolean isSecondaryUseActive() -
wantsToStopRiding
protected boolean wantsToStopRiding() -
isStayingOnGroundSurface
protected boolean isStayingOnGroundSurface() -
updateIsUnderwater
protected boolean updateIsUnderwater() -
turtleHelmetTick
private void turtleHelmetTick() -
createItemCooldowns
-
moveCloak
private void moveCloak() -
updatePlayerPose
protected void updatePlayerPose() -
getPortalWaitTime
public int getPortalWaitTime()- Overrides:
getPortalWaitTimein classEntity
-
getSwimSound
- Overrides:
getSwimSoundin classEntity
-
getSwimSplashSound
- Overrides:
getSwimSplashSoundin classEntity
-
getSwimHighSpeedSplashSound
- Overrides:
getSwimHighSpeedSplashSoundin classEntity
-
getDimensionChangingDelay
public int getDimensionChangingDelay()- Overrides:
getDimensionChangingDelayin classEntity
-
playSound
-
playNotifySound
public void playNotifySound(SoundEvent p_36140_, SoundSource p_36141_, float p_36142_, float p_36143_) -
getSoundSource
- Overrides:
getSoundSourcein classEntity
-
getFireImmuneTicks
protected int getFireImmuneTicks()- Overrides:
getFireImmuneTicksin classEntity
-
handleEntityEvent
public void handleEntityEvent(byte p_36120_) - Overrides:
handleEntityEventin classLivingEntity
-
addParticlesAroundSelf
-
closeContainer
public void closeContainer() -
rideTick
public void rideTick()- Overrides:
rideTickin classLivingEntity
-
serverAiStep
protected void serverAiStep()- Overrides:
serverAiStepin classLivingEntity
-
aiStep
public void aiStep()- Overrides:
aiStepin classLivingEntity
-
playShoulderEntityAmbientSound
-
touch
-
getScore
public int getScore() -
setScore
public void setScore(int p_36398_) -
increaseScore
public void increaseScore(int p_36402_) -
startAutoSpinAttack
public void startAutoSpinAttack(int p_204080_) -
die
- Overrides:
diein classLivingEntity
-
dropEquipment
protected void dropEquipment()- Overrides:
dropEquipmentin classLivingEntity
-
destroyVanishingCursedItems
protected void destroyVanishingCursedItems() -
getHurtSound
- Overrides:
getHurtSoundin classLivingEntity
-
getDeathSound
- Overrides:
getDeathSoundin classLivingEntity
-
drop
-
drop
-
getDestroySpeed
Deprecated. -
getDigSpeed
-
hasCorrectToolForDrops
-
readAdditionalSaveData
- Overrides:
readAdditionalSaveDatain classLivingEntity
-
addAdditionalSaveData
- Overrides:
addAdditionalSaveDatain classLivingEntity
-
isInvulnerableTo
- Overrides:
isInvulnerableToin classEntity
-
hurt
- Overrides:
hurtin classLivingEntity
-
blockUsingShield
- Overrides:
blockUsingShieldin classLivingEntity
-
canBeSeenAsEnemy
public boolean canBeSeenAsEnemy()- Overrides:
canBeSeenAsEnemyin classLivingEntity
-
canHarmPlayer
-
hurtArmor
- Overrides:
hurtArmorin classLivingEntity
-
hurtHelmet
- Overrides:
hurtHelmetin classLivingEntity
-
hurtCurrentlyUsedShield
protected void hurtCurrentlyUsedShield(float p_36383_) - Overrides:
hurtCurrentlyUsedShieldin classLivingEntity
-
actuallyHurt
- Overrides:
actuallyHurtin classLivingEntity
-
onSoulSpeedBlock
protected boolean onSoulSpeedBlock()- Overrides:
onSoulSpeedBlockin classLivingEntity
-
openTextEdit
-
openMinecartCommandBlock
-
openCommandBlock
-
openStructureBlock
-
openJigsawBlock
-
openHorseInventory
-
openMenu
-
sendMerchantOffers
public void sendMerchantOffers(int p_36121_, MerchantOffers p_36122_, int p_36123_, int p_36124_, boolean p_36125_, boolean p_36126_) -
openItemGui
-
interactOn
-
getMyRidingOffset
public double getMyRidingOffset()- Overrides:
getMyRidingOffsetin classEntity
-
removeVehicle
public void removeVehicle()- Overrides:
removeVehiclein classEntity
-
isImmobile
protected boolean isImmobile()- Overrides:
isImmobilein classLivingEntity
-
isAffectedByFluids
public boolean isAffectedByFluids()- Overrides:
isAffectedByFluidsin classLivingEntity
-
maybeBackOffFromEdge
- Overrides:
maybeBackOffFromEdgein classEntity
-
isAboveGround
private boolean isAboveGround() -
attack
-
doAutoAttackOnTouch
- Overrides:
doAutoAttackOnTouchin classLivingEntity
-
disableShield
public void disableShield(boolean p_36385_) -
crit
-
magicCrit
-
sweepAttack
public void sweepAttack() -
respawn
public void respawn() -
remove
-
isLocalPlayer
public boolean isLocalPlayer() -
getGameProfile
public com.mojang.authlib.GameProfile getGameProfile() -
getInventory
-
getAbilities
-
updateTutorialInventoryAction
public void updateTutorialInventoryAction(ItemStack p_150098_, ItemStack p_150099_, ClickAction p_150100_) -
startSleepInBed
public com.mojang.datafixers.util.Either<Player.BedSleepingProblem,Unit> startSleepInBed(BlockPos p_36203_) -
stopSleepInBed
public void stopSleepInBed(boolean p_36226_, boolean p_36227_) -
stopSleeping
public void stopSleeping()- Overrides:
stopSleepingin classLivingEntity
-
findRespawnPositionAndUseSpawnBlock
public static Optional<Vec3> findRespawnPositionAndUseSpawnBlock(ServerLevel p_36131_, BlockPos p_36132_, float p_36133_, boolean p_36134_, boolean p_36135_) -
isSleepingLongEnough
public boolean isSleepingLongEnough() -
getSleepTimer
public int getSleepTimer() -
displayClientMessage
-
awardStat
-
awardStat
-
awardStat
-
awardStat
-
resetStat
-
awardRecipes
-
awardRecipesByKey
-
resetRecipes
-
jumpFromGround
public void jumpFromGround()- Overrides:
jumpFromGroundin classLivingEntity
-
travel
- Overrides:
travelin classLivingEntity
-
updateSwimming
public void updateSwimming()- Overrides:
updateSwimmingin classEntity
-
freeAt
-
getSpeed
public float getSpeed()- Overrides:
getSpeedin classLivingEntity
-
checkMovementStatistics
public void checkMovementStatistics(double p_36379_, double p_36380_, double p_36381_) -
checkRidingStatistics
private void checkRidingStatistics(double p_36388_, double p_36389_, double p_36390_) -
causeFallDamage
- Overrides:
causeFallDamagein classLivingEntity
-
tryToStartFallFlying
public boolean tryToStartFallFlying() -
startFallFlying
public void startFallFlying() -
stopFallFlying
public void stopFallFlying() -
doWaterSplashEffect
protected void doWaterSplashEffect()- Overrides:
doWaterSplashEffectin classEntity
-
getFallSounds
- Overrides:
getFallSoundsin classLivingEntity
-
killed
-
makeStuckInBlock
- Overrides:
makeStuckInBlockin classEntity
-
giveExperiencePoints
public void giveExperiencePoints(int p_36291_) -
getEnchantmentSeed
public int getEnchantmentSeed() -
onEnchantmentPerformed
-
giveExperienceLevels
public void giveExperienceLevels(int p_36276_) -
getXpNeededForNextLevel
public int getXpNeededForNextLevel() -
causeFoodExhaustion
public void causeFoodExhaustion(float p_36400_) -
getFoodData
-
canEat
public boolean canEat(boolean p_36392_) -
isHurt
public boolean isHurt() -
mayBuild
public boolean mayBuild() -
mayUseItemAt
-
getExperienceReward
- Overrides:
getExperienceRewardin classLivingEntity
-
isAlwaysExperienceDropper
protected boolean isAlwaysExperienceDropper()- Overrides:
isAlwaysExperienceDropperin classLivingEntity
-
shouldShowName
public boolean shouldShowName()- Overrides:
shouldShowNamein classLivingEntity
-
getMovementEmission
- Overrides:
getMovementEmissionin classEntity
-
onUpdateAbilities
public void onUpdateAbilities() -
getName
-
getEnderChestInventory
-
getItemBySlot
- Specified by:
getItemBySlotin classLivingEntity
-
setItemSlot
- Specified by:
setItemSlotin classLivingEntity
-
addItem
-
getHandSlots
- Overrides:
getHandSlotsin classEntity
-
getArmorSlots
- Specified by:
getArmorSlotsin classLivingEntity
-
setEntityOnShoulder
-
removeEntitiesOnShoulder
protected void removeEntitiesOnShoulder() -
respawnEntityOnShoulder
-
isSpectator
public abstract boolean isSpectator()- Overrides:
isSpectatorin classEntity
-
isSwimming
public boolean isSwimming()- Overrides:
isSwimmingin classEntity
-
isCreative
public abstract boolean isCreative() -
isPushedByFluid
public boolean isPushedByFluid()- Overrides:
isPushedByFluidin classEntity
-
getScoreboard
-
getDisplayName
- Specified by:
getDisplayNamein interfaceNameable- Overrides:
getDisplayNamein classEntity
-
decorateDisplayNameComponent
-
getScoreboardName
- Overrides:
getScoreboardNamein classEntity
-
getStandingEyeHeight
- Overrides:
getStandingEyeHeightin classLivingEntity
-
setAbsorptionAmount
public void setAbsorptionAmount(float p_36396_) - Overrides:
setAbsorptionAmountin classLivingEntity
-
getAbsorptionAmount
public float getAbsorptionAmount()- Overrides:
getAbsorptionAmountin classLivingEntity
-
createPlayerUUID
-
createPlayerUUID
-
isModelPartShown
-
getSlot
- Overrides:
getSlotin classLivingEntity
-
isReducedDebugInfo
public boolean isReducedDebugInfo() -
setReducedDebugInfo
public void setReducedDebugInfo(boolean p_36394_) -
setRemainingFireTicks
public void setRemainingFireTicks(int p_36353_) - Overrides:
setRemainingFireTicksin classEntity
-
getMainArm
- Specified by:
getMainArmin classLivingEntity
-
setMainArm
-
getShoulderEntityLeft
-
setShoulderEntityLeft
-
getShoulderEntityRight
-
setShoulderEntityRight
-
getCurrentItemAttackStrengthDelay
public float getCurrentItemAttackStrengthDelay() -
getAttackStrengthScale
public float getAttackStrengthScale(float p_36404_) -
resetAttackStrengthTicker
public void resetAttackStrengthTicker() -
getCooldowns
-
getBlockSpeedFactor
protected float getBlockSpeedFactor()- Overrides:
getBlockSpeedFactorin classLivingEntity
-
getLuck
public float getLuck() -
canUseGameMasterBlocks
public boolean canUseGameMasterBlocks() -
canTakeItem
- Overrides:
canTakeItemin classLivingEntity
-
getDimensions
- Overrides:
getDimensionsin classLivingEntity
-
getDismountPoses
- Overrides:
getDismountPosesin classLivingEntity
-
getProjectile
- Overrides:
getProjectilein classLivingEntity
-
eat
- Overrides:
eatin classLivingEntity
-
shouldRemoveSoulSpeed
- Overrides:
shouldRemoveSoulSpeedin classLivingEntity
-
getRopeHoldPosition
- Overrides:
getRopeHoldPositionin classEntity
-
isAlwaysTicking
public boolean isAlwaysTicking()- Specified by:
isAlwaysTickingin interfaceEntityAccess- Overrides:
isAlwaysTickingin classEntity
-
isScoping
public boolean isScoping() -
shouldBeSaved
public boolean shouldBeSaved()- Specified by:
shouldBeSavedin interfaceEntityAccess- Overrides:
shouldBeSavedin classEntity
-
getPrefixes
-
getSuffixes
-
refreshDisplayName
public void refreshDisplayName()Force the displayed name to refresh, by firingPlayerEvent.NameFormat, using the real player name as event parameter. -
getCapability
Description copied from interface:ICapabilityProviderRetrieves the Optional handler for the capability requested on the specific side. The return value CAN be the same for multiple faces. Modders are encouraged to cache this value, using the listener capabilities of the Optional to be notified if the requested capability get lost.- Specified by:
getCapabilityin interfaceICapabilityProvider- Overrides:
getCapabilityin classLivingEntity- Parameters:
capability- The capability to checkfacing- The Side to check from, CAN BE NULL. Null is defined to represent 'internal' or 'self'- Returns:
- The requested an optional holding the requested capability.
-
setForcedPose
Force a pose for the player. If set, the vanilla pose determination and clearance check is skipped. Make sure the pose is clear yourself (e.g. in PlayerTick). This has to be set just once, do not set it every tick. Make sure to clear (null) the pose if not required anymore and only use if necessary. -
getForcedPose
- Returns:
- The forced pose if set, null otherwise
-