This commit is contained in:
gnembon committed 2021-01-15 04:51:06 -04:00
1 parent 3e39548337
commit b14cf288a1
15 files changed
+97 -95

No files matched your search

@@ -47,18 +47,18 @@ import net.minecraft.command.argument.EntityArgumentType;
import net.minecraft.command.argument.EntitySummonArgumentType;
import net.minecraft.command.argument.GameProfileArgumentType;
import net.minecraft.command.argument.IdentifierArgumentType;
import net.minecraft.command.argument.ItemEnchantmentArgumentType;
import net.minecraft.command.argument.EnchantmentArgumentType;
import net.minecraft.command.argument.ItemSlotArgumentType;
import net.minecraft.command.argument.ItemStackArgumentType;
import net.minecraft.command.argument.MessageArgumentType;
import net.minecraft.command.argument.MobEffectArgumentType;
import net.minecraft.command.argument.StatusEffectArgumentType;
import net.minecraft.command.argument.NbtCompoundTagArgumentType;
import net.minecraft.command.argument.NbtPathArgumentType;
import net.minecraft.command.argument.NbtTagArgumentType;
import net.minecraft.command.argument.NumberRangeArgumentType;
import net.minecraft.command.argument.ObjectiveArgumentType;
import net.minecraft.command.argument.ObjectiveCriteriaArgumentType;
import net.minecraft.command.argument.ParticleArgumentType;
import net.minecraft.command.argument.ScoreboardObjectiveArgumentType;
import net.minecraft.command.argument.ScoreboardCriterionArgumentType;
import net.minecraft.command.argument.ParticleEffectArgumentType;
import net.minecraft.command.argument.RotationArgumentType;
import net.minecraft.command.argument.ScoreHolderArgumentType;
import net.minecraft.command.argument.ScoreboardSlotArgumentType;
@@ -152,17 +152,17 @@ public abstract class CommandArgument
new VanillaUnconfigurableArgument("entitytype", EntitySummonArgumentType::entitySummon,
(c, p) -> ValueConversions.of(EntitySummonArgumentType.getEntitySummon(c, p)), SuggestionProviders.SUMMONABLE_ENTITIES
),
new VanillaUnconfigurableArgument("floatrange", NumberRangeArgumentType::method_30918,
new VanillaUnconfigurableArgument("floatrange", NumberRangeArgumentType::floatRange,
(c, p) -> ValueConversions.of(c.getArgument(p, NumberRange.FloatRange.class)), true
),
// function??
new PlayerProfileArgument(),
new VanillaUnconfigurableArgument("intrange", NumberRangeArgumentType::numberRange,
new VanillaUnconfigurableArgument("intrange", NumberRangeArgumentType::intRange,
(c, p) -> ValueConversions.of(NumberRangeArgumentType.IntRangeArgumentType.getRangeArgument(c, p)), true
),
new VanillaUnconfigurableArgument("enchantment", ItemEnchantmentArgumentType::itemEnchantment,
(c, p) -> ValueConversions.of(Registry.ENCHANTMENT.getId(ItemEnchantmentArgumentType.getEnchantment(c, p))), false
new VanillaUnconfigurableArgument("enchantment", EnchantmentArgumentType::enchantment,
(c, p) -> ValueConversions.of(Registry.ENCHANTMENT.getId(EnchantmentArgumentType.getEnchantment(c, p))), false
),
// item_predicate ?? //same as item but accepts tags, not sure right now
new SlotArgument(),
@@ -172,22 +172,22 @@ public abstract class CommandArgument
new VanillaUnconfigurableArgument("message", MessageArgumentType::message,
(c, p) -> new FormattedTextValue(MessageArgumentType.getMessage(c, p)), true
),
new VanillaUnconfigurableArgument("effect", MobEffectArgumentType::mobEffect,
(c, p) -> ValueConversions.of(Registry.STATUS_EFFECT.getId(MobEffectArgumentType.getMobEffect(c, p))),false
new VanillaUnconfigurableArgument("effect", StatusEffectArgumentType::statusEffect,
(c, p) -> ValueConversions.of(Registry.STATUS_EFFECT.getId(StatusEffectArgumentType.getStatusEffect(c, p))),false
),
new TagArgument(), // for nbt_compound_tag and nbt_tag
new VanillaUnconfigurableArgument("path", NbtPathArgumentType::nbtPath,
(c, p) -> StringValue.of(NbtPathArgumentType.getNbtPath(c, p).toString()), true
),
new VanillaUnconfigurableArgument("objective", ObjectiveArgumentType::objective,
(c, p) -> ValueConversions.of(ObjectiveArgumentType.getObjective(c, p)), false
new VanillaUnconfigurableArgument("objective", ScoreboardObjectiveArgumentType::scoreboardObjective,
(c, p) -> ValueConversions.of(ScoreboardObjectiveArgumentType.getObjective(c, p)), false
),
new VanillaUnconfigurableArgument("criterion", ObjectiveCriteriaArgumentType::objectiveCriteria,
(c, p) -> StringValue.of(ObjectiveCriteriaArgumentType.getCriteria(c, p).getName()), false
new VanillaUnconfigurableArgument("criterion", ScoreboardCriterionArgumentType::scoreboardCriterion,
(c, p) -> StringValue.of(ScoreboardCriterionArgumentType.getCriterion(c, p).getName()), false
),
// operation // not sure if we need it, you have scarpet for that
new VanillaUnconfigurableArgument("particle", ParticleArgumentType::particle,
(c, p) -> ValueConversions.of(ParticleArgumentType.getParticle(c, p)), false
new VanillaUnconfigurableArgument("particle", ParticleEffectArgumentType::particleEffect,
(c, p) -> ValueConversions.of(ParticleEffectArgumentType.getParticle(c, p)), false
),
// resource / identifier section