Denizen Script Tags


Tags are always written with a <between these marks>, and are critical to scripts, as the primary way to read data.
Learn about how tags work in The Beginner's Guide.


Showing 1 out of 2425 tags...
Name<CuboidTag.shrink_one_side[<location>]>
ReturnsCuboidTag
DescriptionShrinks the cuboid by the given amount in just one direction, and returns the changed cuboid.
If a coordinate is positive, it will shrink the high value. If it is negative, it will shrink the low value.
Note that you can also specify a single number to expand all coordinates by the same amount (equivalent to specifying a location that is that value on X, Y, and Z).
Inverted by Tag:CuboidTag.expand_one_side
Not valid for multi-member CuboidTags.
If you shrink past the limits of the cuboid's size, the cuboid will flip and start expanding the opposite direction.
Example
# Shrinks the high value of the cuboid "my_cuboid" by 15,16,17 on one side and notes it as "my_smaller_cuboid".
# If "my_cuboid" spans from 10,10,10 (max) to 5,5,5 (min), then shrinking it by 15,16,17 will make "my_smaller_cuboid"
# span from 5,5,5 (max) to -5,-6,-7 (min).
- note <cuboid[my_cuboid].shrink_one_side[15,16,17]> as:my_smaller_cuboid
Example
# Shrinks the low value of the cuboid "my_cuboid" by -15 (-15,-15,-15) on one side and notes it as "my_smaller_cuboid".
# If "my_cuboid" spans from 10,10,10 (max) to 5,5,5 (min), then shrinking it by -15 will make "my_smaller_cuboid"
# span from 20,20,20 (max) to 10,10,10 (min).
- note <cuboid[my_cuboid].shrink_one_side[-15]> as:my_smaller_cuboid
Sourcehttps://github.com/DenizenScript/Denizen/blob/dev/plugin/src/main/java/com/denizenscript/denizen/objects/CuboidTag.java#L1468