Package net.minecraft.client.multiplayer
Class MultiPlayerGameMode
java.lang.Object
net.minecraft.client.multiplayer.MultiPlayerGameMode
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidadjustPlayer(Player p_105222_) voidbooleanbooleancontinueDestroyBlock(BlockPos p_105284_, Direction p_105285_) createPlayer(ClientLevel p_105247_, StatsCounter p_105248_, ClientRecipeBook p_105249_) createPlayer(ClientLevel p_105251_, StatsCounter p_105252_, ClientRecipeBook p_105253_, boolean p_105254_, boolean p_105255_) booleandestroyBlock(BlockPos p_105268_) private voidintvoidhandleCreativeModeItemAdd(ItemStack p_105242_, int p_105243_) voidhandleCreativeModeItemDrop(ItemStack p_105240_) voidhandleInventoryButtonClick(int p_105209_, int p_105210_) voidhandleInventoryMouseClick(int p_171800_, int p_171801_, int p_171802_, ClickType p_171803_, Player p_171804_) voidhandlePickItem(int p_105207_) voidhandlePlaceRecipe(int p_105218_, RecipeHolder<?> p_301105_, boolean p_105220_) voidhandleSlotStateChanged(int p_307527_, int p_307194_, boolean p_307559_) booleanbooleanbooleaninteract(Player p_105227_, Entity p_105228_, InteractionHand p_105229_) interactAt(Player p_105231_, Entity p_105232_, EntityHitResult p_105233_, InteractionHand p_105234_) booleanbooleanbooleanprivate InteractionResultperformUseItemOn(LocalPlayer p_233747_, InteractionHand p_233748_, BlockHitResult p_233749_) voidreleaseUsingItem(Player p_105278_) private booleansameDestroyTarget(BlockPos p_105282_) voidsetLocalMode(GameType p_105280_) voidsetLocalMode(GameType p_171806_, GameType p_171807_) booleanstartDestroyBlock(BlockPos p_105270_, Direction p_105271_) private voidstartPrediction(ClientLevel p_233730_, PredictiveAction p_233731_) voidvoidtick()useItem(Player p_233722_, InteractionHand p_233723_) useItemOn(LocalPlayer p_233733_, InteractionHand p_233734_, BlockHitResult p_233735_)
-
Field Details
-
LOGGER
private static final org.slf4j.Logger LOGGER -
minecraft
-
connection
-
destroyBlockPos
-
destroyingItem
-
destroyProgress
private float destroyProgress -
destroyTicks
private float destroyTicks -
destroyDelay
private int destroyDelay -
isDestroying
private boolean isDestroying -
localPlayerMode
-
previousLocalPlayerMode
-
carriedIndex
private int carriedIndex
-
-
Constructor Details
-
MultiPlayerGameMode
-
-
Method Details
-
adjustPlayer
-
setLocalMode
-
setLocalMode
-
canHurtPlayer
public boolean canHurtPlayer() -
destroyBlock
-
startDestroyBlock
-
stopDestroyBlock
public void stopDestroyBlock() -
continueDestroyBlock
-
startPrediction
-
tick
public void tick() -
sameDestroyTarget
-
ensureHasSentCarriedItem
private void ensureHasSentCarriedItem() -
useItemOn
public InteractionResult useItemOn(LocalPlayer p_233733_, InteractionHand p_233734_, BlockHitResult p_233735_) -
performUseItemOn
private InteractionResult performUseItemOn(LocalPlayer p_233747_, InteractionHand p_233748_, BlockHitResult p_233749_) -
useItem
-
createPlayer
public LocalPlayer createPlayer(ClientLevel p_105247_, StatsCounter p_105248_, ClientRecipeBook p_105249_) -
createPlayer
public LocalPlayer createPlayer(ClientLevel p_105251_, StatsCounter p_105252_, ClientRecipeBook p_105253_, boolean p_105254_, boolean p_105255_) -
attack
-
interact
-
interactAt
public InteractionResult interactAt(Player p_105231_, Entity p_105232_, EntityHitResult p_105233_, InteractionHand p_105234_) -
handleInventoryMouseClick
-
handlePlaceRecipe
-
handleInventoryButtonClick
public void handleInventoryButtonClick(int p_105209_, int p_105210_) -
handleCreativeModeItemAdd
-
handleCreativeModeItemDrop
-
releaseUsingItem
-
hasExperience
public boolean hasExperience() -
hasMissTime
public boolean hasMissTime() -
hasInfiniteItems
public boolean hasInfiniteItems() -
isServerControlledInventory
public boolean isServerControlledInventory() -
isAlwaysFlying
public boolean isAlwaysFlying() -
getPreviousPlayerMode
-
getPlayerMode
-
isDestroying
public boolean isDestroying() -
getDestroyStage
public int getDestroyStage() -
handlePickItem
public void handlePickItem(int p_105207_) -
handleSlotStateChanged
public void handleSlotStateChanged(int p_307527_, int p_307194_, boolean p_307559_)
-