类 MultiPlayerGameMode

java.lang.Object
net.minecraft.client.multiplayer.MultiPlayerGameMode

public class MultiPlayerGameMode extends Object
  • 字段详细资料

    • LOGGER

      private static final org.slf4j.Logger LOGGER
    • minecraft

      private final Minecraft minecraft
    • connection

      private final ClientPacketListener connection
    • destroyBlockPos

      private BlockPos destroyBlockPos
    • destroyingItem

      private ItemStack destroyingItem
    • destroyProgress

      private float destroyProgress
    • destroyTicks

      private float destroyTicks
    • destroyDelay

      private int destroyDelay
    • isDestroying

      private boolean isDestroying
    • localPlayerMode

      private GameType localPlayerMode
    • previousLocalPlayerMode

      @Nullable private GameType previousLocalPlayerMode
    • carriedIndex

      private int carriedIndex
  • 构造器详细资料

  • 方法详细资料

    • adjustPlayer

      public void adjustPlayer(Player pPlayer)
    • setLocalMode

      public void setLocalMode(GameType pLocalPlayerMode, @Nullable GameType pPreviousLocalPlayerMode)
    • setLocalMode

      public void setLocalMode(GameType pType)
    • canHurtPlayer

      public boolean canHurtPlayer()
    • destroyBlock

      public boolean destroyBlock(BlockPos pPos)
    • startDestroyBlock

      public boolean startDestroyBlock(BlockPos pLoc, Direction pFace)
    • stopDestroyBlock

      public void stopDestroyBlock()
    • continueDestroyBlock

      public boolean continueDestroyBlock(BlockPos pPosBlock, Direction pDirectionFacing)
    • startPrediction

      private void startPrediction(ClientLevel p_233730_, PredictiveAction p_233731_)
    • getPickRange

      public float getPickRange()
    • tick

      public void tick()
    • sameDestroyTarget

      private boolean sameDestroyTarget(BlockPos pPos)
    • ensureHasSentCarriedItem

      private void ensureHasSentCarriedItem()
    • useItemOn

      public InteractionResult useItemOn(LocalPlayer pPlayer, InteractionHand pHand, BlockHitResult pResult)
    • performUseItemOn

      private InteractionResult performUseItemOn(LocalPlayer pPlayer, InteractionHand pHand, BlockHitResult pResult)
    • useItem

      public InteractionResult useItem(Player pPlayer, InteractionHand pHand)
    • createPlayer

      public LocalPlayer createPlayer(ClientLevel pLevel, StatsCounter pStatsManager, ClientRecipeBook pRecipes)
    • createPlayer

      public LocalPlayer createPlayer(ClientLevel pLevel, StatsCounter pStatsManager, ClientRecipeBook pRecipes, boolean pWasShiftKeyDown, boolean pWasSprinting)
    • attack

      public void attack(Player pPlayer, Entity pTargetEntity)
    • interact

      public InteractionResult interact(Player pPlayer, Entity pTarget, InteractionHand pHand)
    • interactAt

      public InteractionResult interactAt(Player pPlayer, Entity pTarget, EntityHitResult pRay, InteractionHand pHand)
    • handleInventoryMouseClick

      public void handleInventoryMouseClick(int pContainerId, int pSlotId, int pMouseButton, ClickType pClickType, Player pPlayer)
    • handlePlaceRecipe

      public void handlePlaceRecipe(int pContainerId, Recipe<?> pRecipe, boolean pPlaceAll)
    • handleInventoryButtonClick

      public void handleInventoryButtonClick(int pContainerId, int pButtonId)
    • handleCreativeModeItemAdd

      public void handleCreativeModeItemAdd(ItemStack pStack, int pSlotId)
    • handleCreativeModeItemDrop

      public void handleCreativeModeItemDrop(ItemStack pStack)
    • releaseUsingItem

      public void releaseUsingItem(Player pPlayer)
    • hasExperience

      public boolean hasExperience()
    • hasMissTime

      public boolean hasMissTime()
    • hasInfiniteItems

      public boolean hasInfiniteItems()
    • hasFarPickRange

      public boolean hasFarPickRange()
    • isServerControlledInventory

      public boolean isServerControlledInventory()
    • isAlwaysFlying

      public boolean isAlwaysFlying()
    • getPreviousPlayerMode

      @Nullable public GameType getPreviousPlayerMode()
    • getPlayerMode

      public GameType getPlayerMode()
    • isDestroying

      public boolean isDestroying()
    • getDestroyStage

      public int getDestroyStage()
    • handlePickItem

      public void handlePickItem(int pIndex)