ide.mcc 12.6 KB
Newer Older
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
# InitalizeIDE
{"type":"impulse", "auto": true, "conditional": false}
// function
{"type":"chain", "auto": true}
/gamerule commandBlockOutput true
/gamerule disableElytraMovementCheck false
/gamerule doDaylightCycle false
/gamerule doEntityDrops false
/gamerule doFireTick false
/gamerule doMobLoot false
/gamerule doMobSpawning false
/gamerule doTileDrops false
/gamerule keepInventory true
/gamerule logAdminCommands false
/gamerule mobGriefing false
/gamerule naturalRegeneration true
/gamerule randomTickSpeed 0
/gamerule reducedDebugInfo false
/gamerule sendCommandFeedback true
/gamerule showDeathMessages true
/gamerule spawnRadius 7
/gamerule spectatorsGenerateChunks false
/scoreboard objectives add loop_interval dummy
/scoreboard objectives add loop_tick dummy
/scoreboard objectives add success_count dummy
/scoreboard objectives add dev dummy
/execute @e[type=ArmorStand,name=HackSmeltToIDE] ~1 ~-1 ~ /blockdata ~ ~ ~ {auto:1}

# HackSmeltToIDE
{"type":"impulse", "auto": false, "conditional": false}
/blockdata ~ ~ ~ {auto:0}
{"type":"chain", "auto": true}
/kill @e[type=AreaEffectCloud,tag=IDE]
/execute @e[type=ArmorStand,name=InitalizeIDE] ~ ~ ~-1 /summon AreaEffectCloud ~ ~ ~ {Duration:2147483647, CustomNameVisible:1, Tags:["CloudFunction","IDE"], CustomName:"ide.mcc"}
/execute @e[type=ArmorStand,name=InitalizeIDE] ~ ~ ~ /summon AreaEffectCloud ~1 ~ ~ {Duration:2147483647, CustomNameVisible:1, Tags:["CloudFunction","IDE"], CustomName:"InitalizeIDE"}
/execute @e[type=ArmorStand,name=HackSmeltToIDE] ~ ~ ~ /summon AreaEffectCloud ~1 ~ ~ {Duration:2147483647, CustomNameVisible:1, Tags:["CloudFunction","IDE"], CustomName:"HackSmeltToIDE"}
/execute @e[type=ArmorStand,name=RunProcesses] ~ ~ ~ /summon AreaEffectCloud ~1 ~ ~ {Duration:2147483647, CustomNameVisible:1, Tags:["CloudFunction","IDE"], CustomName:"RunProcesses"}
/execute @e[type=ArmorStand,name=PrintMenu] ~ ~ ~ /summon AreaEffectCloud ~1 ~ ~ {Duration:2147483647, CustomNameVisible:1, Tags:["CloudFunction","IDE"], CustomName:"PrintMenu"}
/execute @e[type=ArmorStand,name=MenuTeleportToDev] ~ ~ ~ /summon AreaEffectCloud ~1 ~ ~ {Duration:2147483647, CustomNameVisible:1, Tags:["CloudFunction","IDE"], CustomName:"MenuTeleportToDev"}
/execute @e[type=ArmorStand,name=MenuTeleportToGame] ~ ~ ~ /summon AreaEffectCloud ~1 ~ ~ {Duration:2147483647, CustomNameVisible:1, Tags:["CloudFunction","IDE"], CustomName:"MenuTeleportToGame"}
/execute @e[type=ArmorStand,name=TestforAndGiveDevTools] ~ ~ ~ /summon AreaEffectCloud ~1 ~ ~ {Duration:2147483647, CustomNameVisible:1, Tags:["CloudFunction","IDE"], CustomName:"TestforAndGiveDevTools"}
/kill @e[tag=oc_marker]

# RunProcesses
{"type":"repeating", "auto": true, "conditional": false}
// empty
{"type":"chain"}
/execute @e[type=AreaEffectCloud,tag=loop] ~ ~ ~ /execute @e[type=AreaEffectCloud,r=0,c=1,tag=LoopConstant] ~ ~ ~ /scoreboard players tag @e[type=AreaEffectCloud,r=0,c=1] add run
/execute @e[type=AreaEffectCloud,tag=loop] ~ ~ ~ /execute @e[type=AreaEffectCloud,r=0,c=1,tag=LoopConstant] ~ ~ ~ /scoreboard players tag @e[type=AreaEffectCloud,r=0,c=1] add LoopActive
/execute @e[type=AreaEffectCloud,tag=loop] ~ ~ ~ /execute @e[type=AreaEffectCloud,r=0,c=1,tag=LoopConstant] ~ ~ ~ /scoreboard players tag @e[type=AreaEffectCloud,r=0,c=1] remove loop
/execute @e[type=AreaEffectCloud,tag=loop] ~ ~ ~ /execute @e[type=AreaEffectCloud,r=0,c=1,tag=LoopInterval] ~ ~ ~ /scoreboard players operation @e[type=AreaEffectCloud,r=0,c=1] loop_tick = @e[type=AreaEffectCloud,r=0,c=1] loop_interval
/execute @e[type=AreaEffectCloud,tag=loop] ~ ~ ~ /execute @e[type=AreaEffectCloud,r=0,c=1,tag=LoopInterval] ~ ~ ~ /scoreboard players tag @e[type=AreaEffectCloud,r=0,c=1] add LoopActive
/execute @e[type=AreaEffectCloud,tag=loop] ~ ~ ~ /execute @e[type=AreaEffectCloud,r=0,c=1,tag=LoopInterval] ~ ~ ~ /scoreboard players tag @e[type=AreaEffectCloud,r=0,c=1] remove loop
/execute @e[type=AreaEffectCloud,tag=end] ~ ~ ~ /scoreboard players tag @e[type=AreaEffectCloud,r=0,c=1] remove pause
/execute @e[type=AreaEffectCloud,tag=end] ~ ~ ~ /scoreboard players tag @e[type=AreaEffectCloud,r=0,c=1] remove continue
/execute @e[type=AreaEffectCloud,tag=end] ~ ~ ~ /scoreboard players tag @e[type=AreaEffectCloud,r=0,c=1] remove LoopActive
/execute @e[type=AreaEffectCloud,tag=end] ~ ~ ~ /scoreboard players tag @e[type=AreaEffectCloud,r=0,c=1] remove run
/scoreboard players reset @e[type=AreaEffectCloud,tag=end] loop_tick
/scoreboard players tag @e[type=AreaEffectCloud,tag=continue] remove pause
/scoreboard players tag @e[type=AreaEffectCloud,tag=continue] add LoopActive
/scoreboard players tag @e[type=AreaEffectCloud,tag=continue] remove continue
/execute @e[type=AreaEffectCloud,tag=pause] ~ ~ ~ /scoreboard players tag @e[type=AreaEffectCloud,r=0,c=1,tag=run] remove run
/execute @e[type=AreaEffectCloud,tag=pause] ~ ~ ~ /scoreboard players tag @e[type=AreaEffectCloud,r=0,c=1,tag=LoopActive] remove LoopActive
/scoreboard players remove @e[type=AreaEffectCloud,tag=LoopActive,score_loop_tick_min=1] loop_tick 1
/scoreboard players tag @e[type=AreaEffectCloud,tag=LoopActive,score_loop_tick=0] add run
	{"conditional":true}
	/execute @e[type=AreaEffectCloud,tag=LoopActive,score_loop_tick=0] ~ ~ ~ /scoreboard players operation @e[type=AreaEffectCloud,r=0,c=1] loop_tick = @e[type=AreaEffectCloud,r=0,c=1] loop_interval
	{"conditional":false}
/scoreboard players tag @e[type=AreaEffectCloud,tag=end] remove run
/scoreboard players tag @e[type=AreaEffectCloud,name=CloudDelay] add run {Age:-1}
/execute @e[type=AreaEffectCloud,tag=run] ~ ~ ~ /blockdata ~ ~-1 ~ {auto:1b}
/execute @e[type=AreaEffectCloud,tag=run] ~ ~ ~ /scoreboard players tag @e[type=AreaEffectCloud,r=0,c=1,tag=!LoopConstant] add end
/scoreboard players tag @e[type=AreaEffectCloud,tag=end] remove run
/execute @e[type=AreaEffectCloud,tag=end] ~ ~ ~ /blockdata ~ ~-1 ~ {auto:0b}
/scoreboard players tag @e[type=AreaEffectCloud,tag=end] remove end

# PrintMenu
{"type":"repeating", "auto": true, "conditional": false}
/testfor @a[m=1,rxm=90,rx=90,tag=!MenuOpened]
	{"type":"chain", "conditional": true}
	/tellraw @a[m=1,rxm=90,rx=90,tag=!MenuOpened] {"translate":"ide.message","color":"green","with":[{"translate":"ide.name","color":"dark_green","hoverEvent":{"action":"show_text","value":{"translate":"Ideal Development Environment\nby Moesh (http://moesh.ca)"}},"clickEvent":{"action":"open_url","value":"http://moesh.ca"}},{"translate":"ide.menu.message","with":[{"translate":"ide.menu.tools","color":"white","hoverEvent":{"action":"show_text","value":{"translate":"ide.menu.tools.usage"}},"clickEvent":{"action":"run_command","value":"/scoreboard players tag @p[m=1,c=1] add NeedsDevTools"}},{"translate":"ide.menu.clear","with":[{"translate":"ide.menu.clear.inventory","color":"white","hoverEvent":{"action":"show_text","value":{"translate":"ide.menu.clear.inventory.usage"}},"clickEvent":{"action":"run_command","value":"/clear"}},{"translate":"ide.menu.clear.effects","color":"white","hoverEvent":{"action":"show_text","value":{"translate":"ide.menu.clear.effects.usage"}},"clickEvent":{"action":"run_command","value":"/effect @p clear"}}]},{"translate":"ide.menu.nightVision","color":"white","hoverEvent":{"action":"show_text","value":{"translate":"ide.menu.nightVision.usage"}},"clickEvent":{"action":"run_command","value":"/effect @p minecraft:night_vision 999999 0 true"}},{"text":"\n"},{"translate":"ide.menu.suggest","hoverEvent":{"action":"show_text","value":{"translate":"ide.menu.suggest.usage"}},"with":[{"translate":"Sidebar","color":"white","hoverEvent":{"action":"show_text","value":{"translate":"ide.menu.suggest.tag.sidebar.usage"}},"clickEvent":{"action":"suggest_command","value":"/scoreboard objectives setdisplay sidebar "}},{"translate":"ide.menu.suggest.tag.tagAreaEffectCloud","color":"white","hoverEvent":{"action":"show_text","value":{"translate":"ide.menu.suggest.tag.tagAreaEffectCloud.usage"}},"clickEvent":{"action":"suggest_command","value":"/scoreboard players tag @e[type=AreaEffectCloud,name="}},{"translate":"ide.menu.suggest.tag.tagClosestAreaEffectCloud","color":"white","hoverEvent":{"action":"show_text","value":{"translate":"ide.menu.suggest.tag.tagClosestAreaEffectCloud.usage"}},"clickEvent":{"action":"suggest_command","value":"/scoreboard players tag @e[type=AreaEffectCloud,c=1] "}},{"translate":"ide.menu.suggest.target.closestAreaEffectCloud","color":"white","hoverEvent":{"action":"show_text","value":{"translate":"ide.menu.suggest.target.closestAreaEffectCloud.usage"}},"clickEvent":{"action":"suggest_command","value":"/ @e[type=AreaEffectCloud,c=1] "}}]}]}]}
	/scoreboard players tag @a[m=1,rxm=90,rx=90,tag=!MenuOpened] add MenuOpened
	{"conditional": false}
/scoreboard players tag @a[m=1,rx=89,tag=MenuOpened] remove MenuOpened

# MenuTeleportToDev
{"type":"repeating", "auto": true, "conditional": false}
/testfor @a[tag=TeleportToDev]
	{"type":"chain", "conditional": true}
	/tp @a[tag=TeleportToDev] 0 3 0
	/scoreboard players tag @a[tag=TeleportToDev] remove TeleportToDev

# MenuTeleportToGame
{"type":"repeating", "auto": true, "conditional": false}
/testfor @a[tag=TeleportToGame]
	{"type":"chain", "conditional": true}
	/tp @a[tag=TeleportToGame] 0 114 1000
	/scoreboard players tag @a[tag=TeleportToGame] remove TeleportToGame

# TestforAndGiveDevTools
{"type":"repeating", "auto": true, "conditional": false}
/testfor @a[m=1,tag=NeedsDevTools]
	{"type":"chain", "conditional": true}
	/replaceitem entity @a[m=1,tag=NeedsDevTools] slot.hotbar.0 minecraft:command_block
	/replaceitem entity @a[m=1,tag=NeedsDevTools] slot.hotbar.1 minecraft:chain_command_block
	/replaceitem entity @a[m=1,tag=NeedsDevTools] slot.hotbar.2 minecraft:redstone_block
	/replaceitem entity @a[m=1,tag=NeedsDevTools] slot.hotbar.3 minecraft:structure_block
	/replaceitem entity @a[m=1,tag=NeedsDevTools] slot.hotbar.4 minecraft:stone_button
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
	/scoreboard players tag @a[m=1,tag=NeedsDevTools] remove NeedsDevTools

# ReplaceWithDelayCloudBlock
{"type":"repeating", "auto": true, "conditional": false}
/testfor @e[type=AreaEffectCloud,tag=ReplaceWithDelayCloudBlock]
{"type":"chain"}
/execute @e[type=AreaEffectCloud,tag=ReplaceWithDelayCloudBlock] ~ ~ ~ /testforblock ~ ~ ~ minecraft:command_block 0
	{"conditional": true}
	/execute @e[type=AreaEffectCloud,tag=ReplaceWithDelayCloudBlock] ~ ~ ~ /setblock ~ ~ ~ minecraft:chain_command_block 0
	/execute @e[type=AreaEffectCloud,tag=ReplaceWithDelayCloudBlock] ~ ~ ~ /blockdata ~ ~ ~ {Command:"summon AreaEffectCloud ~ ~ ~ {CustomName:\"CloudDelay\",Age:-20}"}
	{"conditional": false}
/execute @e[type=AreaEffectCloud,tag=ReplaceWithDelayCloudBlock] ~ ~ ~ /testforblock ~ ~ ~ minecraft:command_block 1
	{"conditional": true}
	/execute @e[type=AreaEffectCloud,tag=ReplaceWithDelayCloudBlock] ~ ~ ~ /setblock ~ ~ ~ minecraft:chain_command_block 1
	/execute @e[type=AreaEffectCloud,tag=ReplaceWithDelayCloudBlock] ~ ~ ~ /blockdata ~ ~ ~ {Command:"summon AreaEffectCloud ~ ~2 ~ {CustomName:\"CloudDelay\",Age:-20}"}
	{"conditional": false}
/execute @e[type=AreaEffectCloud,tag=ReplaceWithDelayCloudBlock] ~ ~ ~ /testforblock ~ ~ ~ minecraft:command_block 2
	{"conditional": true}
	/execute @e[type=AreaEffectCloud,tag=ReplaceWithDelayCloudBlock] ~ ~ ~ /setblock ~ ~ ~ minecraft:chain_command_block 2
	/execute @e[type=AreaEffectCloud,tag=ReplaceWithDelayCloudBlock] ~ ~ ~ /blockdata ~ ~ ~ {Command:"summon AreaEffectCloud ~ ~1 ~-1 {CustomName:\"CloudDelay\",Age:-20}"}
	{"conditional": false}
/execute @e[type=AreaEffectCloud,tag=ReplaceWithDelayCloudBlock] ~ ~ ~ /testforblock ~ ~ ~ minecraft:command_block 3
	{"conditional": true}
	/execute @e[type=AreaEffectCloud,tag=ReplaceWithDelayCloudBlock] ~ ~ ~ /setblock ~ ~ ~ minecraft:chain_command_block 3
	/execute @e[type=AreaEffectCloud,tag=ReplaceWithDelayCloudBlock] ~ ~ ~ /blockdata ~ ~ ~ {Command:"summon AreaEffectCloud ~ ~1 ~1 {CustomName:\"CloudDelay\",Age:-20}"}
	{"conditional": false}
/execute @e[type=AreaEffectCloud,tag=ReplaceWithDelayCloudBlock] ~ ~ ~ /testforblock ~ ~ ~ minecraft:command_block 4
	{"conditional": true}
	/execute @e[type=AreaEffectCloud,tag=ReplaceWithDelayCloudBlock] ~ ~ ~ /setblock ~ ~ ~ minecraft:chain_command_block 4
	/execute @e[type=AreaEffectCloud,tag=ReplaceWithDelayCloudBlock] ~ ~ ~ /blockdata ~ ~ ~ {Command:"summon AreaEffectCloud ~-1 ~1 ~ {CustomName:\"CloudDelay\",Age:-20}"}
	{"conditional": false}
/execute @e[type=AreaEffectCloud,tag=ReplaceWithDelayCloudBlock] ~ ~ ~ /testforblock ~ ~ ~ minecraft:command_block 5
	{"conditional": true}
	/execute @e[type=AreaEffectCloud,tag=ReplaceWithDelayCloudBlock] ~ ~ ~ /setblock ~ ~ ~ minecraft:chain_command_block 5
	/execute @e[type=AreaEffectCloud,tag=ReplaceWithDelayCloudBlock] ~ ~ ~ /blockdata ~ ~ ~ {Command:"summon AreaEffectCloud ~1 ~1 ~ {CustomName:\"CloudDelay\",Age:-20}"}
	{"conditional": false}
/kill @e[type=AreaEffectCloud,tag=ReplaceWithDelayCloudBlock]