Join
Joins all the specified strings into a single string and uses it as the provided value.
Type ID: kaya:join
Format
| Field | Type | Default | Description |
|---|---|---|---|
strings |
Array of String Providers | The strings to join together. | |
separator |
String Provider | The string to place between each string when joined. |
Example
{
"type": "kaya:join",
"strings": [
"tellraw @a {\"text\": \"",
{
"type": "kaya:escape",
"string": {
"type": "kaya:nbt",
"source": {
"type": "kaya:block",
"block": "used_block"
},
"path": "{}"
}
},
"\", \"color\": \"gray\", \"italic\": true}"
],
"separator": ""
}
This example joins three strings:
- A constant '
tellraw @a {"text": "' string. - An escaped stringified NBT of the block provided by the
kaya:used_blockcontext parameter. - A constant '
", "color": "gray", "italic": true}' string.
History
| Minecraft | Mod | Changelog |
| 1.21.5 | 0.1.0 | Added the type. |