Denizen Script Mechanisms


Mechanisms are found in object properties, the 'adjust' command, and similar. These are used to change the state of an object.
Learn about how mechanisms work in The Beginner's Guide.


Showing 1 out of 632 mechanisms...
Nameadd_member
ObjectCuboidTag
Input(#,)CuboidTag
Related Tags<CuboidTag.get> Returns a cuboid representing the one component of this cuboid (for cuboids that contain multiple sub-cuboids).
<CuboidTag.add_member[<cuboid>]> Returns a modified copy of this cuboid, with the input cuboid(s) added at the end.
<CuboidTag.add_member[<cuboid>].at[<#>]> Returns a modified copy of this cuboid, with the input cuboid(s) added at the specified index.
DescriptionAdds a sub-member to the cuboid (optionally at a specified index - otherwise, at the end).
Input is of the form like "2,cu@..." where 2 is the sub-cuboid index, or just a direct CuboidTag input.
Note that the index is where the member will end up. So, index 1 will add the cuboid as the very first member (moving the rest up +1 index value).
Example
# Adds "my_second_cuboid" as a member to "my_cuboid" and narrates a formatted list of members.
# For example, if "my_cuboid" is "world,5,5,5,10,10,10" and "my_second_cuboid" is "world,12,12,12,22,22,22",
# then this will narrate "world,5,5,5,10,10,10 and world,12,12,12,22,22,22".
- adjust <cuboid[my_cuboid]> add_member:my_second_cuboid
- narrate <cuboid[my_cuboid].list_members.formatted>
Example
# Adds "my_second_cuboid" as a member to "my_cuboid" at the second index.
- adjust <cuboid[my_cuboid]> add_member:2,my_second_cuboid
Sourcehttps://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/CuboidTag.java#L1787