类 ItemCommands
java.lang.Object
net.minecraft.server.commands.ItemCommands
-
字段概要
字段修饰符和类型字段说明private static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType
private static final com.mojang.brigadier.exceptions.Dynamic3CommandExceptionType
(专用程序包) static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType
private static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType
private static final com.mojang.brigadier.exceptions.Dynamic2CommandExceptionType
(专用程序包) static final com.mojang.brigadier.exceptions.Dynamic3CommandExceptionType
private static final com.mojang.brigadier.suggestion.SuggestionProvider<CommandSourceStack>
-
构造器概要
构造器 -
方法概要
修饰符和类型方法说明private static ItemStack
applyModifier
(CommandSourceStack pSource, LootItemFunction pModifier, ItemStack pItem) private static int
blockToBlock
(CommandSourceStack pSource, BlockPos pSourcePos, int pSourceSlot, BlockPos pPos, int pSlot) private static int
blockToBlock
(CommandSourceStack pSource, BlockPos pSourcePos, int pSourceSlot, BlockPos pPos, int pSlot, LootItemFunction pModifier) private static int
blockToEntities
(CommandSourceStack pSource, BlockPos pPos, int pSourceSlot, Collection<? extends Entity> pTargets, int pSlot) private static int
blockToEntities
(CommandSourceStack pSource, BlockPos pPos, int pSourceSlot, Collection<? extends Entity> pTargets, int pSlot, LootItemFunction pModifier) private static int
entityToBlock
(CommandSourceStack pSource, Entity pSourceEntity, int pSourceSlot, BlockPos pPos, int pSlot) private static int
entityToBlock
(CommandSourceStack pSource, Entity pSourceEntity, int pSourceSlot, BlockPos pPos, int pSlot, LootItemFunction pModifier) private static int
entityToEntities
(CommandSourceStack pSource, Entity pSourceEntity, int pSourceSlot, Collection<? extends Entity> pTargets, int pSlot) private static int
entityToEntities
(CommandSourceStack pSource, Entity pSourceEntity, int pSourceSlot, Collection<? extends Entity> pTargets, int pSlot, LootItemFunction pModifier) private static ItemStack
getBlockItem
(CommandSourceStack pSource, BlockPos pPos, int pSlot) private static Container
getContainer
(CommandSourceStack pSource, BlockPos pPos, com.mojang.brigadier.exceptions.Dynamic3CommandExceptionType p_180330_) private static ItemStack
getEntityItem
(Entity pEntity, int pSlot) private static int
modifyBlockItem
(CommandSourceStack pSource, BlockPos pPos, int pSlot, LootItemFunction pModifier) private static int
modifyEntityItem
(CommandSourceStack pSource, Collection<? extends Entity> pTargets, int pSlot, LootItemFunction pModifier) static void
register
(com.mojang.brigadier.CommandDispatcher<CommandSourceStack> pDispatcher, CommandBuildContext pContext) private static int
setBlockItem
(CommandSourceStack pSource, BlockPos pPos, int pSlot, ItemStack pItem) private static int
setEntityItem
(CommandSourceStack pSource, Collection<? extends Entity> pTargets, int pSlot, ItemStack pItem)
-
字段详细资料
-
ERROR_TARGET_NOT_A_CONTAINER
static final com.mojang.brigadier.exceptions.Dynamic3CommandExceptionType ERROR_TARGET_NOT_A_CONTAINER -
ERROR_SOURCE_NOT_A_CONTAINER
private static final com.mojang.brigadier.exceptions.Dynamic3CommandExceptionType ERROR_SOURCE_NOT_A_CONTAINER -
ERROR_TARGET_INAPPLICABLE_SLOT
static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType ERROR_TARGET_INAPPLICABLE_SLOT -
ERROR_SOURCE_INAPPLICABLE_SLOT
private static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType ERROR_SOURCE_INAPPLICABLE_SLOT -
ERROR_TARGET_NO_CHANGES
private static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType ERROR_TARGET_NO_CHANGES -
ERROR_TARGET_NO_CHANGES_KNOWN_ITEM
private static final com.mojang.brigadier.exceptions.Dynamic2CommandExceptionType ERROR_TARGET_NO_CHANGES_KNOWN_ITEM -
SUGGEST_MODIFIER
private static final com.mojang.brigadier.suggestion.SuggestionProvider<CommandSourceStack> SUGGEST_MODIFIER
-
-
构造器详细资料
-
ItemCommands
public ItemCommands()
-
-
方法详细资料
-
register
public static void register(com.mojang.brigadier.CommandDispatcher<CommandSourceStack> pDispatcher, CommandBuildContext pContext) -
modifyBlockItem
private static int modifyBlockItem(CommandSourceStack pSource, BlockPos pPos, int pSlot, LootItemFunction pModifier) throws com.mojang.brigadier.exceptions.CommandSyntaxException - 抛出:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
modifyEntityItem
private static int modifyEntityItem(CommandSourceStack pSource, Collection<? extends Entity> pTargets, int pSlot, LootItemFunction pModifier) throws com.mojang.brigadier.exceptions.CommandSyntaxException - 抛出:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
setBlockItem
private static int setBlockItem(CommandSourceStack pSource, BlockPos pPos, int pSlot, ItemStack pItem) throws com.mojang.brigadier.exceptions.CommandSyntaxException - 抛出:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
getContainer
private static Container getContainer(CommandSourceStack pSource, BlockPos pPos, com.mojang.brigadier.exceptions.Dynamic3CommandExceptionType p_180330_) throws com.mojang.brigadier.exceptions.CommandSyntaxException - 抛出:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
setEntityItem
private static int setEntityItem(CommandSourceStack pSource, Collection<? extends Entity> pTargets, int pSlot, ItemStack pItem) throws com.mojang.brigadier.exceptions.CommandSyntaxException - 抛出:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
blockToEntities
private static int blockToEntities(CommandSourceStack pSource, BlockPos pPos, int pSourceSlot, Collection<? extends Entity> pTargets, int pSlot) throws com.mojang.brigadier.exceptions.CommandSyntaxException - 抛出:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
blockToEntities
private static int blockToEntities(CommandSourceStack pSource, BlockPos pPos, int pSourceSlot, Collection<? extends Entity> pTargets, int pSlot, LootItemFunction pModifier) throws com.mojang.brigadier.exceptions.CommandSyntaxException - 抛出:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
blockToBlock
private static int blockToBlock(CommandSourceStack pSource, BlockPos pSourcePos, int pSourceSlot, BlockPos pPos, int pSlot) throws com.mojang.brigadier.exceptions.CommandSyntaxException - 抛出:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
blockToBlock
private static int blockToBlock(CommandSourceStack pSource, BlockPos pSourcePos, int pSourceSlot, BlockPos pPos, int pSlot, LootItemFunction pModifier) throws com.mojang.brigadier.exceptions.CommandSyntaxException - 抛出:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
entityToBlock
private static int entityToBlock(CommandSourceStack pSource, Entity pSourceEntity, int pSourceSlot, BlockPos pPos, int pSlot) throws com.mojang.brigadier.exceptions.CommandSyntaxException - 抛出:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
entityToBlock
private static int entityToBlock(CommandSourceStack pSource, Entity pSourceEntity, int pSourceSlot, BlockPos pPos, int pSlot, LootItemFunction pModifier) throws com.mojang.brigadier.exceptions.CommandSyntaxException - 抛出:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
entityToEntities
private static int entityToEntities(CommandSourceStack pSource, Entity pSourceEntity, int pSourceSlot, Collection<? extends Entity> pTargets, int pSlot) throws com.mojang.brigadier.exceptions.CommandSyntaxException - 抛出:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
entityToEntities
private static int entityToEntities(CommandSourceStack pSource, Entity pSourceEntity, int pSourceSlot, Collection<? extends Entity> pTargets, int pSlot, LootItemFunction pModifier) throws com.mojang.brigadier.exceptions.CommandSyntaxException - 抛出:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
applyModifier
private static ItemStack applyModifier(CommandSourceStack pSource, LootItemFunction pModifier, ItemStack pItem) -
getEntityItem
private static ItemStack getEntityItem(Entity pEntity, int pSlot) throws com.mojang.brigadier.exceptions.CommandSyntaxException - 抛出:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
getBlockItem
private static ItemStack getBlockItem(CommandSourceStack pSource, BlockPos pPos, int pSlot) throws com.mojang.brigadier.exceptions.CommandSyntaxException - 抛出:
com.mojang.brigadier.exceptions.CommandSyntaxException
-