-
Notifications
You must be signed in to change notification settings - Fork 12
3 Slots And Requirements
Yanbing Zhao edited this page Jun 20, 2019
·
8 revisions
As an example, here is a configuration that can sell wheats and deduct the corresponding amount of money:
Slot0 {
Item {
Count = 1
ItemType = "minecraft:wheat"
UnsafeDamage = 0
DisplayName = "&lWheat seller"
ItemLore = [
"&ePrice for %player_name%: $10 => 9 wheats"
"&eYou can left or right click to buy some wheats"
]
}
Action {
Command = "cost: 10; console: give %player_name% minecraft:wheat 9"
KeepInventoryOpen = true
}
Requirements = "%economy_balance% >= 10"
}
The configuration for slots contains 8 options, 3 of which are shown above:
Item
Action
Requirements
And there are also 5 options not shown above:
PrimaryAction
SecondaryAction
PrimaryShiftAction
SecondaryShiftAction
IgnoredPermissions