added support for block predicate argument support and tag_matches function. Fixes #563
This commit is contained in:
1 parent
076ad62fad
commit
e15afd9763
16 files changed
+187
-13
No files matched your search
@@ -36,6 +36,7 @@ import net.minecraft.advancement.Advancement;
|
||||
import net.minecraft.command.CommandSource;
|
||||
import net.minecraft.command.argument.AngleArgumentType;
|
||||
import net.minecraft.command.argument.BlockPosArgumentType;
|
||||
import net.minecraft.command.argument.BlockPredicateArgumentType;
|
||||
import net.minecraft.command.argument.BlockStateArgument;
|
||||
import net.minecraft.command.argument.BlockStateArgumentType;
|
||||
import net.minecraft.command.argument.ColorArgumentType;
|
||||
@@ -126,6 +127,9 @@ public abstract class CommandArgument
|
||||
},
|
||||
false
|
||||
),
|
||||
new VanillaUnconfigurableArgument( "blockpredicate", BlockPredicateArgumentType::blockPredicate,
|
||||
(c, p) -> ValueConversions.ofBlockPredicate(c.getSource().getMinecraftServer().getTagManager(), BlockPredicateArgumentType.getBlockPredicate(c, p)), false
|
||||
),
|
||||
// block_predicate todo - not sure about the returned format. Needs to match block tags used in the API (future)
|
||||
new VanillaUnconfigurableArgument("teamcolor", ColorArgumentType::color,
|
||||
(c, p) -> {
|
||||
|
||||
Reference in new issue
Block a user