Denizen Script Commands


Commands are always written with a '-' before them, and are the core component of any script, the primary way to cause things to happen.
Learn about how commands work in The Beginner's Guide.


Showing 1 out of 184 commands...
NameCreate
Syntaxcreate [<entity>] [<name>] (<location>) (traits:<trait>|...) (registry:<name>)
Short DescriptionCreates a new NPC, and optionally spawns it at a location.
Full DescriptionCreates an npc which the entity type specified, or specify an existing npc to create a copy.
If no location is specified the npc is created despawned.
Use the 'save:<savename>' argument to return the npc for later use in a script.

Optionally specify a list of traits to immediately apply when creating the NPC.

Optionally specify a custom registry to create the NPC into. (Most users, leave this option off).
Will generate a new registry if needed.
Related Tags<server.npcs> Returns a list of all NPCs.
<entry[saveName].created_npc> returns the NPC that was created.
Usage Example
# Use to create a despawned NPC for later usage.
- create player Bob
Usage Example
# Use to create an NPC and spawn it immediately.
- create spider Joe <player.location>
Groupnpc
RequiresCitizens
Sourcehttps://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/scripts/commands/npc/CreateCommand.java#L29