/
example2.conf
127 lines (127 loc) · 3.82 KB
/
example2.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
aliases {
compass-item {
Item {
Count = 1
ItemType = "minecraft:compass"
UnsafeDamage = 0
DisplayName = "&lAnother way to open the GUI"
ItemLore = [
"&eYou can open the GUI in the game"
"&ewhen you &lleft click&r &eby the &lcompass"
"&eWhat happened when you right click it?"
]
}
Action {
Command = "console: say %player_name% has found the magic power of the compass!"
}
}
clock-item {
Item {
Count = 1
ItemType = "minecraft:clock"
UnsafeDamage = 0
DisplayName = "&lAnother way to open the GUI"
ItemLore = [
"&eYou can open the GUI in the game"
"&ewhen you &lleft click&r &eby the &lcompass"
"&eWhat happened when you right click it?"
"&e&l================================"
"&eIn fact, &lnothing will happen"
"&ebecause you do not have the permission for"
"&eopening that GUI (&cvirtualchest.open.self.example&e)"
]
}
Requirements = "!player.hasPermission('virtualchest.open.self.example')"
Action {
Command = "console: say %player_name% found nothing."
}
}
white-pane-item {
Item {
Count = 1
ItemType = "minecraft:stained_glass_pane"
UnsafeDamage = 0
DisplayName = "&e&lIt will be changed to &8&lblack&e&l in 10 ticks (0.5s)"
}
Requirements = "tick % 20 < 10"
}
black-pane-item {
Item {
Count = 1
ItemType = "minecraft:stained_glass_pane"
UnsafeDamage = 15
DisplayName = "&e&lIt will be changed to &f&lwhite&e&l in 10 ticks (0.5s)"
}
Requirements = "tick % 20 >= 10"
}
}
virtualchest {
TextTitle = "&1&lExample 2"
Rows = 2
UpdateIntervalTick = 10
OpenActionCommand = """sound: minecraft:block.note.harp:1.6;
delay: 5;
sound: minecraft:block.note.harp;
delay: 5;
sound: minecraft:block.note.harp:0.625;
tell: Hello, %player_name%!;
broadcast: &9[Server]&r Player %player_name% has opened example2."""
CloseActionCommand = """sound-with-pitch: minecraft:block.note.harp:1.6:1.5;
delay: 5;
sound-with-pitch: minecraft:block.note.harp:1.5;
delay: 5;
sound-with-pitch: minecraft:block.note.harp:0.625:1.5;
tell: Goodbye, %player_name%!;
broadcast: &9[Server]&r Player %player_name% has closed example2."""
Slot0 = [
${aliases.white-pane-item}
${aliases.black-pane-item}
]
Slot8 = [
${aliases.clock-item}
${aliases.compass-item}
]
Slot9 = [
${aliases.white-pane-item}
${aliases.black-pane-item}
]
Slot17 = [{
Item {
Count = 1
ItemType = "minecraft:emerald_block"
UnsafeDamage = 0
DisplayName = "&lGoodbye! %player_name%"
ItemLore = [
"&eYou will open another chest GUI"
"&eIt will take you 7 if you click this item"
"&eYou have %economy_bal_format% now"
]
}
Requirements = "%economy_balance% >= 7"
PrimaryAction {
Command = "cost: 7; console: virtualchest open example %player_name%"
KeepInventoryOpen = true
}
SecondaryAction {
Command = "cost: 7; console: virtualchest open example %player_name%"
KeepInventoryOpen = true
}
}, {
Item {
Count = 1
ItemType = "minecraft:barrier"
UnsafeDamage = 0
DisplayName = "&lOops! %player_name%"
ItemLore = [
"&eYou want to open another chest GUI"
"&eBut you do not have enough money (7)"
"&eYou have %economy_bal_format% now"
]
}
}]
TriggerItem {
ItemType = "minecraft:compass"
EnablePrimaryAction = true
EnableSecondaryAction = false
}
}