Package baritone.api.utils
Interface IPlayerContext
public interface IPlayerContext
- Since:
- 11/12/2018
- Author:
- Brady
-
Method Summary
Modifier and TypeMethodDescriptiondefault Iterable<net.minecraft.world.entity.Entity> entities()default Stream<net.minecraft.world.entity.Entity> static doubleeyeHeight(boolean ifSneaking) Deprecated.Use entity.getEyeHeight(Pose.CROUCHING) insteaddefault Optional<net.minecraft.core.BlockPos> Returns the block that the crosshair is currently placed over.default booleanisLookingAt(net.minecraft.core.BlockPos pos) net.minecraft.client.Minecraftnet.minecraft.world.phys.HitResultnet.minecraft.client.player.LocalPlayerplayer()default BetterBlockPosdefault net.minecraft.world.phys.Vec3default net.minecraft.world.phys.Vec3default net.minecraft.world.phys.Vec3default Rotationnet.minecraft.world.level.Levelworld()
-
Method Details
-
minecraft
net.minecraft.client.Minecraft minecraft() -
player
net.minecraft.client.player.LocalPlayer player() -
playerController
-
world
net.minecraft.world.level.Level world() -
entities
-
entitiesStream
-
worldData
-
objectMouseOver
net.minecraft.world.phys.HitResult objectMouseOver() -
playerFeet
-
playerFeetAsVec
-
playerHead
-
playerMotion
-
viewerPos
-
playerRotations
-
eyeHeight
Deprecated.Use entity.getEyeHeight(Pose.CROUCHING) insteadReturns the player's eye height, taking into account whether or not the player is sneaking.- Parameters:
ifSneaking- Whether or not the player is sneaking- Returns:
- The player's eye height
-
getSelectedBlock
Returns the block that the crosshair is currently placed over. Updated once per tick.- Returns:
- The position of the highlighted block
-
isLookingAt
-