-
-
Notifications
You must be signed in to change notification settings - Fork 2
Variable: insert
Misat11 edited this page May 9, 2020
·
4 revisions
This variable inserts contents of items variable into another item or items.
Yaml:
# Example
- insert: main
items:
- STONE
- DIRT
- stack: LIME_WOOL
id: myMenu
# Example 2
- insert:
- main
- $myMenu # it will be inserted to current end of this category
- $myBlock # it will be inserted to start of this category on its initialization
items:
- STONE
- DIRT
- stack: GLOWSTONE
id: myBlock
Groovy:
inventory {
// Example
insert ('main') {
item('STONE')
item('DIRT')
}
item('LIME_WOOL') {
id '$myMenu'
}
// Example 2
insert ([
'main',
'$myMenu', // it will be inserted to current end of this category
'$myBlock' // it will be inserted to start of this category on its initialization
]) {
item('STONE')
item('DIRT')
}
item('GLOWSTONE') {
id 'myBlock'
}
}
Can't find what are you looking for on this wiki? Maybe our automatically generated javadoc could help you https://docs.screamingsandals.org/simpleinventories/simpleinventories-core/
- Welcome on this wiki
- Formats:
- Variables:
- Callbacks: (Groovy only)
-
Examples:
- Making shop (Groovy only)
- Making vault shop (Groovy only)