Search in sources :

Example 31 with InvalidArgumentsException

use of com.denizenscript.denizencore.exceptions.InvalidArgumentsException in project Denizen-For-Bukkit by DenizenScript.

the class AdvancementCommand method parseArgs.

// <--[command]
// @Name Advancement
// @Syntax advancement [id:<name>] (delete/grant:<players>/revoke:<players>/{create}) (parent:<name>) (icon:<item>) (title:<text>) (description:<text>) (background:<key>) (frame:<type>) (toast:<boolean>) (announce:<boolean>) (hidden:<boolean>) (x:<offset>) (y:<offset>) (progress_length:<#>)
// @Required 1
// @Maximum 14
// @Short Controls a custom advancement.
// @Group player
// 
// @Description
// Controls custom Minecraft player advancements. You should generally create advancements manually on server start.
// Currently, the ID argument may only refer to advancements added through this command.
// The default action is to create and register a new advancement.
// You may also delete an existing advancement, in which case do not provide any further arguments.
// You may grant or revoke an advancement for a list of players, in which case do not provide any further arguments.
// The parent argument sets the root advancement in the advancements menu, in the format "namespace:key".
// If no namespace is specified, the parent is assumed to have been created through this command.
// The icon argument sets the icon displayed in toasts and the advancements menu.
// The title argument sets the title that will show on toasts and in the advancements menu.
// The description argument sets the information that will show when scrolling over a chat announcement or in the advancements menu.
// The background argument sets the image to use if the advancement goes to a new tab.
// If the background is unspecified, defaults to "minecraft:textures/gui/advancements/backgrounds/stone.png".
// The frame argument sets the type of advancement - valid arguments are CHALLENGE, GOAL, and TASK.
// The toast argument sets whether the advancement should display a toast message when a player completes it. Default is true.
// The announce argument sets whether the advancement should display a chat message to the server when a player completes it. Default is true.
// The hidden argument sets whether the advancement should be hidden until it is completed.
// The x and y arguments are offsets based on the size of an advancement icon in the menu. They are required for custom tabs to look reasonable.
// 
// When creating an advancement, optionally specify 'progress_length' to make it require multiple parts.
// When granting an advancement, optionally specify 'progress_length' to only grant partial progress.
// 
// To award a pre-existing vanilla advancement, instead use <@link mechanism PlayerTag.award_advancement>
// 
// WARNING: Failure to re-create advancements on every server start may result in loss of data - use <@link event server prestart>.
// 
// @Tags
// <PlayerTag.has_advancement[<advancement>]>
// <PlayerTag.advancements>
// <server.advancement_types>
// 
// @Usage
// Creates a new advancement that has a potato icon.
// - advancement id:hello_world icon:baked_potato "title:Hello World" "description:You said hello to the world."
// 
// @Usage
// Creates a new advancement with the parent "hello_world" and a CHALLENGE frame. Hidden until it is completed.
// - advancement id:hello_universe parent:hello_world icon:ender_pearl "title:Hello Universe" "description:You said hello to the UNIVERSE." frame:challenge hidden:true x:1
// 
// @Usage
// Grants the "hello_world" advancement to the current player.
// - advancement id:hello_world grant:<player>
// 
// -->
@Override
public void parseArgs(ScriptEntry scriptEntry) throws InvalidArgumentsException {
    for (Argument arg : scriptEntry) {
        if (!scriptEntry.hasObject("id") && arg.matchesPrefix("id")) {
            scriptEntry.addObject("id", arg.asElement());
        } else if (!scriptEntry.hasObject("parent") && arg.matchesPrefix("parent")) {
            scriptEntry.addObject("parent", arg.asElement());
        } else if (!scriptEntry.hasObject("create") && arg.matches("create")) {
            // unused, just to be explicit
            scriptEntry.addObject("create", new ElementTag(true));
        } else if (!scriptEntry.hasObject("delete") && arg.matches("delete", "remove")) {
            scriptEntry.addObject("delete", new ElementTag(true));
        } else if (!scriptEntry.hasObject("grant") && arg.matchesPrefix("grant", "give", "g") && arg.matchesArgumentList(PlayerTag.class)) {
            scriptEntry.addObject("grant", arg.asType(ListTag.class));
        } else if (!scriptEntry.hasObject("revoke") && arg.matchesPrefix("revoke", "take", "r") && arg.matchesArgumentList(PlayerTag.class)) {
            scriptEntry.addObject("revoke", arg.asType(ListTag.class));
        } else if (!scriptEntry.hasObject("icon") && arg.matchesPrefix("icon", "i") && arg.matchesArgumentType(ItemTag.class)) {
            scriptEntry.addObject("icon", arg.asType(ItemTag.class));
        } else if (!scriptEntry.hasObject("title") && arg.matchesPrefix("title", "text", "t")) {
            scriptEntry.addObject("title", arg.asElement());
        } else if (!scriptEntry.hasObject("description") && arg.matchesPrefix("description", "desc", "d")) {
            scriptEntry.addObject("description", arg.asElement());
        } else if (!scriptEntry.hasObject("background") && arg.matchesPrefix("background", "bg")) {
            scriptEntry.addObject("background", arg.asElement());
        } else if (!scriptEntry.hasObject("frame") && arg.matchesPrefix("frame", "f") && arg.matchesEnum(Advancement.Frame.class)) {
            scriptEntry.addObject("frame", arg.asElement());
        } else if (!scriptEntry.hasObject("toast") && arg.matchesPrefix("toast", "show") && arg.matchesBoolean()) {
            scriptEntry.addObject("toast", arg.asElement());
        } else if (!scriptEntry.hasObject("announce") && arg.matchesPrefix("announce", "chat") && arg.matchesBoolean()) {
            scriptEntry.addObject("announce", arg.asElement());
        } else if (!scriptEntry.hasObject("hidden") && arg.matchesPrefix("hidden", "hide", "h") && arg.matchesBoolean()) {
            scriptEntry.addObject("hidden", arg.asElement());
        } else if (!scriptEntry.hasObject("x") && arg.matchesPrefix("x") && arg.matchesFloat()) {
            scriptEntry.addObject("x", arg.asElement());
        } else if (!scriptEntry.hasObject("y") && arg.matchesPrefix("y") && arg.matchesFloat()) {
            scriptEntry.addObject("y", arg.asElement());
        } else if (!scriptEntry.hasObject("progress_length") && arg.matchesPrefix("progress_length") && arg.matchesInteger()) {
            scriptEntry.addObject("progress_length", arg.asElement());
        } else {
            arg.reportUnhandled();
        }
    }
    if (!scriptEntry.hasObject("id")) {
        throw new InvalidArgumentsException("Must specify an ID!");
    }
    scriptEntry.defaultObject("icon", new ItemTag(Material.AIR));
    scriptEntry.defaultObject("title", new ElementTag(""));
    scriptEntry.defaultObject("description", new ElementTag(""));
    scriptEntry.defaultObject("background", new ElementTag("minecraft:textures/gui/advancements/backgrounds/stone.png"));
    scriptEntry.defaultObject("frame", new ElementTag("TASK"));
    scriptEntry.defaultObject("toast", new ElementTag(true));
    scriptEntry.defaultObject("announce", new ElementTag(true));
    scriptEntry.defaultObject("hidden", new ElementTag(false));
    scriptEntry.defaultObject("x", new ElementTag(0f));
    scriptEntry.defaultObject("y", new ElementTag(0f));
}
Also used : Argument(com.denizenscript.denizencore.objects.Argument) PlayerTag(com.denizenscript.denizen.objects.PlayerTag) ElementTag(com.denizenscript.denizencore.objects.core.ElementTag) ItemTag(com.denizenscript.denizen.objects.ItemTag) ListTag(com.denizenscript.denizencore.objects.core.ListTag) InvalidArgumentsException(com.denizenscript.denizencore.exceptions.InvalidArgumentsException)

Example 32 with InvalidArgumentsException

use of com.denizenscript.denizencore.exceptions.InvalidArgumentsException in project Denizen-For-Bukkit by DenizenScript.

the class ChatCommand method parseArgs.

// TODO: Should the chat command be in the NPC group instead?
// <--[command]
// @Name Chat
// @Syntax chat [<text>] (no_target/targets:<entity>|...) (talkers:<entity>|...) (range:<#.#>)
// @Required 1
// @Maximum 4
// @Plugin Citizens
// @Short Causes an NPC/NPCs to send a chat message to nearby players.
// @Synonyms Say,Speak
// @Group player
// 
// @Description
// Chat uses an NPC's speech controller provided by Denizen, typically inside 'interact' or 'task' script-containers.
// Typically there is already player and NPC context inside a queue that is using the 'chat' command.
// In this case, only a text input is required.
// Alternatively, target entities can be specified to have any Entity chat to a different target/targets,
// or specify 'no_target' to not send the message to any specific target.
// 
// Chat from an NPC is formatted by the settings present in Denizen's config.yml.
// Players being chatted to see a slightly different message than surrounding players.
// By default, a 'chat' will allow other players nearby to also see the conversation. For example:
// <code>
// - chat 'Hello!'
// </code>
// The player being chatted to, by default the attached Player to the script queue, will see a message 'Jack says to you, Hello!',
// however surrounding entities will see something along the lines of 'Jack says to Bob, Hello!'.
// The format for this is configurable.
// 
// If sending messages to the Player without any surrounding entities hearing the message is desirable,
// it is often times recommended to instead use the 'narrate' command.
// Alternatively, on a server-wide scale, the configuration node for the 'range' can be set to 0, however this is discouraged.
// 
// @Tags
// None
// 
// @Usage
// Use to emulate an NPC talking out loud to a Player within an interact script-container.
// - chat "Hello, <player.name>! Nice day, eh?"
// 
// @Usage
// Use to have an NPC talk to a group of individuals.
// - chat targets:<npc.location.find_players_within[6].filter[has_flag[clan_initiate]]> "Welcome, initiate!"
// -->
@Override
public void parseArgs(ScriptEntry scriptEntry) throws InvalidArgumentsException {
    boolean specified_targets = false;
    boolean specified_talker = false;
    for (Argument arg : scriptEntry) {
        if (arg.matchesPrefix("target", "targets", "t")) {
            if (arg.matchesArgumentList(EntityTag.class)) {
                scriptEntry.addObject("targets", arg.asType(ListTag.class));
            }
            specified_targets = true;
        } else if (arg.matches("no_target")) {
            scriptEntry.addObject("targets", new ListTag());
        } else if (arg.matchesPrefix("talker", "talkers")) {
            if (arg.matchesArgumentList(EntityTag.class)) {
                scriptEntry.addObject("talkers", arg.asType(ListTag.class));
            }
            specified_talker = true;
        } else if (arg.matchesPrefix("range", "r")) {
            if (arg.matchesFloat()) {
                scriptEntry.addObject("range", arg.asElement());
            }
        } else if (!scriptEntry.hasObject("message")) {
            scriptEntry.addObject("message", arg.getRawElement());
        } else {
            arg.reportUnhandled();
        }
    }
    if (!scriptEntry.hasObject("targets") && Utilities.entryHasPlayer(scriptEntry) && !specified_targets) {
        scriptEntry.defaultObject("targets", new ListTag(Utilities.getEntryPlayer(scriptEntry)));
    }
    if (!scriptEntry.hasObject("talkers") && Utilities.entryHasNPC(scriptEntry) && !specified_talker) {
        scriptEntry.defaultObject("talkers", new ListTag(Utilities.getEntryNPC(scriptEntry)));
    }
    if (!scriptEntry.hasObject("targets")) {
        throw new InvalidArgumentsException("Must specify valid targets!");
    }
    if (!scriptEntry.hasObject("talkers")) {
        throw new InvalidArgumentsException("Must specify valid talkers!");
    }
    if (!scriptEntry.hasObject("message")) {
        throw new InvalidArgumentsException("Must specify a message!");
    }
    scriptEntry.defaultObject("range", new ElementTag(Settings.chatBystandersRange()));
}
Also used : Argument(com.denizenscript.denizencore.objects.Argument) ElementTag(com.denizenscript.denizencore.objects.core.ElementTag) ListTag(com.denizenscript.denizencore.objects.core.ListTag) InvalidArgumentsException(com.denizenscript.denizencore.exceptions.InvalidArgumentsException)

Example 33 with InvalidArgumentsException

use of com.denizenscript.denizencore.exceptions.InvalidArgumentsException in project Denizen-For-Bukkit by DenizenScript.

the class SidebarCommand method parseArgs.

@Override
public void parseArgs(ScriptEntry scriptEntry) throws InvalidArgumentsException {
    Action action = Action.SET;
    for (Argument arg : ArgumentHelper.interpret(scriptEntry, scriptEntry.getOriginalArguments())) {
        if (!scriptEntry.hasObject("action") && arg.matchesEnum(Action.class)) {
            action = Action.valueOf(arg.getValue().toUpperCase());
        } else if (!scriptEntry.hasObject("title") && arg.matchesPrefix("title", "t", "objective", "obj", "o")) {
            scriptEntry.addObject("title", arg.asElement());
        } else if (!scriptEntry.hasObject("scores") && arg.matchesPrefix("scores", "score", "lines", "line", "l")) {
            scriptEntry.addObject("scores", arg.asElement());
        } else if (!scriptEntry.hasObject("value") && arg.matchesPrefix("value", "values", "val", "v")) {
            scriptEntry.addObject("value", arg.asElement());
        } else if (!scriptEntry.hasObject("increment") && arg.matchesPrefix("increment", "inc", "i")) {
            scriptEntry.addObject("increment", arg.asElement());
        } else if (!scriptEntry.hasObject("start") && arg.matchesPrefix("start", "s")) {
            scriptEntry.addObject("start", arg.asElement());
        } else if (!scriptEntry.hasObject("players") && arg.matchesPrefix("players", "player", "p")) {
            scriptEntry.addObject("players", arg.asElement());
        } else if (!scriptEntry.hasObject("per_player") && arg.matches("per_player")) {
            scriptEntry.addObject("per_player", new ElementTag(true));
        } else {
            arg.reportUnhandled();
        }
    }
    if (action == Action.ADD && !scriptEntry.hasObject("value")) {
        throw new InvalidArgumentsException("Must specify value(s) for that action!");
    }
    if (action == Action.SET && !scriptEntry.hasObject("value") && !scriptEntry.hasObject("title") && !scriptEntry.hasObject("increment") && !scriptEntry.hasObject("start")) {
        throw new InvalidArgumentsException("Must specify at least one of: value(s), title, increment, or start for that action!");
    }
    if (action == Action.SET && scriptEntry.hasObject("scores") && !scriptEntry.hasObject("value")) {
        throw new InvalidArgumentsException("Must specify value(s) when setting scores!");
    }
    scriptEntry.addObject("action", new ElementTag(action.name()));
    scriptEntry.defaultObject("per_player", new ElementTag(false));
    scriptEntry.defaultObject("players", new ElementTag(Utilities.entryHasPlayer(scriptEntry) ? Utilities.getEntryPlayer(scriptEntry).identify() : "li@"));
}
Also used : Argument(com.denizenscript.denizencore.objects.Argument) ElementTag(com.denizenscript.denizencore.objects.core.ElementTag) InvalidArgumentsException(com.denizenscript.denizencore.exceptions.InvalidArgumentsException)

Example 34 with InvalidArgumentsException

use of com.denizenscript.denizencore.exceptions.InvalidArgumentsException in project Denizen-For-Bukkit by DenizenScript.

the class TeamCommand method parseArgs.

// <--[command]
// @Name Team
// @Syntax team (id:<scoreboard>/{main}) [name:<team>] (add:<entry>|...) (remove:<entry>|...) (prefix:<prefix>) (suffix:<suffix>) (option:<type> status:<status>) (color:<color>)
// @Required 2
// @Maximum 9
// @Short Controls scoreboard teams.
// @Group player
// 
// @Description
// The Team command allows you to control a scoreboard team.
// 
// Use the "prefix" or "suffix" arguments to modify a team's playername prefix and suffix.
// NOTE: Prefixes and suffixes cannot be longer than 16 characters!
// 
// The "entry" value can be a player's name to affect that player, or an entity's UUID to affect that entity.
// You can alternately input a raw PlayerTag or EntityTag, and they will be automatically translated to the name/UUID internally.
// 
// Use the "color" argument to set the team color (for glowing, names, etc). Must be from <@link url https://hub.spigotmc.org/javadocs/spigot/org/bukkit/ChatColor.html>.
// 
// Use the "add" and "remove" arguments to add or remove players by name to/from the team.
// 
// Use the "option" and "status" arguments together to set a team option's status.
// Option can be "COLLISION_RULE", "DEATH_MESSAGE_VISIBILITY", or "NAME_TAG_VISIBILITY", with status "ALWAYS", "FOR_OTHER_TEAMS", "FOR_OWN_TEAM", or "NEVER".
// Option can instead be "FRIENDLY_FIRE" or "SEE_INVISIBLE", only allowing status "ALWAYS" or "NEVER".
// 
// @Tags
// <server.scoreboard[(<board>)].team[<team>].members>
// 
// @Usage
// Use to add a player to a team.
// - team name:red add:<player>
// 
// @Usage
// Use to add some mob to a team.
// - team name:blue add:<player.location.find_entities[monster].within[10]>
// 
// @Usage
// Use to change the prefix for a team.
// - team name:red "prefix:[<red>Red Team<reset>]"
// 
// @Usage
// Use to hide nameplates for members of a team.
// - team name:red option:name_tag_visibility status:never
// -->
@Override
public void parseArgs(ScriptEntry scriptEntry) throws InvalidArgumentsException {
    String name = null;
    String prefix = null;
    String suffix = null;
    for (Argument arg : scriptEntry) {
        if (arg.matchesPrefix("id") && !scriptEntry.hasObject("id")) {
            scriptEntry.addObject("id", arg.asElement());
        } else if (arg.matchesPrefix("name") && !scriptEntry.hasObject("name")) {
            ElementTag nameElement = arg.asElement();
            name = nameElement.asString();
            scriptEntry.addObject("name", nameElement);
        } else if (arg.matchesPrefix("add") && !scriptEntry.hasObject("add")) {
            scriptEntry.addObject("add", arg.asType(ListTag.class));
        } else if (arg.matchesPrefix("remove") && !scriptEntry.hasObject("remove")) {
            scriptEntry.addObject("remove", arg.asType(ListTag.class));
        } else if (arg.matchesPrefix("prefix") && !scriptEntry.hasObject("prefix")) {
            ElementTag prefixElement = arg.asElement();
            prefix = prefixElement.asString();
            scriptEntry.addObject("prefix", prefixElement);
        } else if (arg.matchesPrefix("suffix") && !scriptEntry.hasObject("suffix")) {
            ElementTag suffixElement = arg.asElement();
            suffix = suffixElement.asString();
            scriptEntry.addObject("suffix", suffixElement);
        } else if (arg.matchesPrefix("color") && arg.matchesEnum(ChatColor.class) && !scriptEntry.hasObject("color")) {
            scriptEntry.addObject("color", arg.asElement());
        } else if (arg.matchesPrefix("option") && !scriptEntry.hasObject("option") && (arg.matchesEnum(Team.Option.class) || arg.matches("friendly_fire", "see_invisible"))) {
            scriptEntry.addObject("option", arg.asElement());
        } else if (arg.matchesPrefix("status") && !scriptEntry.hasObject("status") && arg.matchesEnum(Team.OptionStatus.class)) {
            scriptEntry.addObject("status", arg.asElement());
        } else {
            arg.reportUnhandled();
        }
    }
    if (name == null || name.length() == 0 || name.length() > 16) {
        throw new InvalidArgumentsException("Must specify a team name between 1 and 16 characters!");
    }
    if (!scriptEntry.hasObject("add") && !scriptEntry.hasObject("remove") && !scriptEntry.hasObject("option") && !scriptEntry.hasObject("color") && !scriptEntry.hasObject("prefix") && !scriptEntry.hasObject("suffix")) {
        throw new InvalidArgumentsException("Must specify something to do with the team!");
    }
    if ((prefix != null && prefix.length() > 64) || (suffix != null && suffix.length() > 64)) {
        throw new InvalidArgumentsException("Prefixes and suffixes must be 64 characters or less!");
    }
    if (scriptEntry.hasObject("option") != scriptEntry.hasObject("status")) {
        throw new InvalidArgumentsException("Option and Status arguments must go together!");
    }
    scriptEntry.defaultObject("id", new ElementTag("main"));
}
Also used : Argument(com.denizenscript.denizencore.objects.Argument) Team(org.bukkit.scoreboard.Team) ElementTag(com.denizenscript.denizencore.objects.core.ElementTag) ListTag(com.denizenscript.denizencore.objects.core.ListTag) InvalidArgumentsException(com.denizenscript.denizencore.exceptions.InvalidArgumentsException)

Example 35 with InvalidArgumentsException

use of com.denizenscript.denizencore.exceptions.InvalidArgumentsException in project Denizen-For-Bukkit by DenizenScript.

the class FakeEquipCommand method parseArgs.

// <--[command]
// @Name FakeEquip
// @Syntax fakeequip [<entity>|...] (for:<player>|...) (duration:<duration>/reset) (hand:<item>) (offhand:<item>) (head:<item>) (chest:<item>) (legs:<item>) (boots:<item>)
// @Required 1
// @Maximum 9
// @Short Fake-equips items and armor on a list of entities for players to see without real change.
// @Group entity
// 
// @Description
// This command fake-equips items and armor on a list of entities.
// 
// The change doesn't happen on-server, and no armor effects will happen from it.
// 
// The equipment can only be seen by certain players. By default, the linked player is used.
// 
// The changes will remain in place for as long as the duration is specified (even if the real equipment is changed).
// The changes can be manually reset early by using the 'reset' argument.
// If you do not provide a duration, the fake equipment will last until manually reset.
// This does not persist across server restarts.
// 
// Set the item to 'air' to unequip any slot.
// 
// @Tags
// <EntityTag.equipment>
// <InventoryTag.equipment>
// 
// @Usage
// Use to fake-equip a stone block on the player's head.
// - fakeequip <player> head:stone duration:10s
// 
// @Usage
// Use to fake-equip an iron helmet on two defined players.
// - fakeequip <[player]>|<[someplayer]> head:iron_helmet duration:1m
// 
// @Usage
// Use to fake-unequip all armor off the player.
// - fakeequip <player> head:air chest:air legs:air boots:air duration:5s
// 
// @Usage
// Use to make all players within 30 blocks of an entity see it permanently equip a shield.
// - fakeequip <[entity]> offhand:shield for:<[entity].find_players_within[30]> duration:0
// 
// -->
@Override
public void parseArgs(ScriptEntry scriptEntry) throws InvalidArgumentsException {
    EquipmentOverride equipment = new EquipmentOverride();
    for (Argument arg : scriptEntry) {
        if (!scriptEntry.hasObject("entities") && arg.matchesArgumentList(EntityTag.class)) {
            scriptEntry.addObject("entities", arg.asType(ListTag.class).filter(EntityTag.class, scriptEntry));
        } else if (arg.matchesPrefix("duration") && arg.matchesArgumentType(DurationTag.class)) {
            scriptEntry.addObject("duration", arg.asType(DurationTag.class));
        } else if (arg.matches("reset")) {
            scriptEntry.addObject("reset", new ElementTag(true));
        } else if (arg.matchesPrefix("for") && arg.matchesArgumentList(PlayerTag.class)) {
            scriptEntry.addObject("for", arg.asType(ListTag.class).filter(PlayerTag.class, scriptEntry));
        } else if (arg.matchesPrefix("head", "helmet") && arg.matchesArgumentType(ItemTag.class)) {
            equipment.head = arg.asType(ItemTag.class);
        } else if (arg.matchesPrefix("chest", "chestplate") && arg.matchesArgumentType(ItemTag.class)) {
            equipment.chest = arg.asType(ItemTag.class);
        } else if (arg.matchesPrefix("legs", "leggings") && arg.matchesArgumentType(ItemTag.class)) {
            equipment.legs = arg.asType(ItemTag.class);
        } else if (arg.matchesPrefix("boots", "feet") && arg.matchesArgumentType(ItemTag.class)) {
            equipment.boots = arg.asType(ItemTag.class);
        } else if (arg.matchesPrefix("offhand") && arg.matchesArgumentType(ItemTag.class)) {
            equipment.offhand = arg.asType(ItemTag.class);
        } else if (arg.matchesPrefix("hand") && arg.matchesArgumentType(ItemTag.class)) {
            equipment.hand = arg.asType(ItemTag.class);
        } else {
            arg.reportUnhandled();
        }
    }
    if (equipment.isEmpty() && !scriptEntry.hasObject("reset")) {
        throw new InvalidArgumentsException("Must specify equipment!");
    }
    if (!scriptEntry.hasObject("for")) {
        PlayerTag player = Utilities.getEntryPlayer(scriptEntry);
        if (player == null) {
            throw new InvalidArgumentsException("Must specify a for player!");
        }
        scriptEntry.addObject("for", Collections.singletonList(player));
    }
    scriptEntry.addObject("equipment", equipment);
}
Also used : Argument(com.denizenscript.denizencore.objects.Argument) PlayerTag(com.denizenscript.denizen.objects.PlayerTag) EntityTag(com.denizenscript.denizen.objects.EntityTag) ElementTag(com.denizenscript.denizencore.objects.core.ElementTag) ItemTag(com.denizenscript.denizen.objects.ItemTag) ListTag(com.denizenscript.denizencore.objects.core.ListTag) InvalidArgumentsException(com.denizenscript.denizencore.exceptions.InvalidArgumentsException)

Aggregations

InvalidArgumentsException (com.denizenscript.denizencore.exceptions.InvalidArgumentsException)41 ElementTag (com.denizenscript.denizencore.objects.core.ElementTag)31 Argument (com.denizenscript.denizencore.objects.Argument)30 EntityTag (com.denizenscript.denizen.objects.EntityTag)15 ListTag (com.denizenscript.denizencore.objects.core.ListTag)14 LocationTag (com.denizenscript.denizen.objects.LocationTag)11 DurationTag (com.denizenscript.denizencore.objects.core.DurationTag)11 ItemTag (com.denizenscript.denizen.objects.ItemTag)8 PlayerTag (com.denizenscript.denizen.objects.PlayerTag)7 ScriptTag (com.denizenscript.denizencore.objects.core.ScriptTag)5 FormatScriptContainer (com.denizenscript.denizen.scripts.containers.core.FormatScriptContainer)3 MaterialTag (com.denizenscript.denizen.objects.MaterialTag)2 ArrayList (java.util.ArrayList)2 ParticleHelper (com.denizenscript.denizen.nms.abstracts.ParticleHelper)1 AssignmentTrait (com.denizenscript.denizen.npc.traits.AssignmentTrait)1 ColorTag (com.denizenscript.denizen.objects.ColorTag)1 NPCTag (com.denizenscript.denizen.objects.NPCTag)1 WorldTag (com.denizenscript.denizen.objects.WorldTag)1 AssignmentScriptContainer (com.denizenscript.denizen.scripts.containers.core.AssignmentScriptContainer)1 InteractScriptContainer (com.denizenscript.denizen.scripts.containers.core.InteractScriptContainer)1