OneCommand使用方式:
和原来一样,将指令放入普通命令方块中,然后激活即可。
使用含有fill的指令方块就可以移除模块
- summon FallingSand ~ ~.6 ~ {Time:1,Block:log,Passengers:[{id:FallingSand,Time:1,Block:redstone_block,Passengers:[{id:FallingSand,Time:1,Block:activator_rail,Passengers:[{id:MinecartCommandBlock,Command:gamerule commandBlockOutput false},{id:MinecartCommandBlock,Command:gamerule logAdminCommands false},{id:MinecartCommandBlock,Command:fill ~2 ~-3 ~0 ~5 ~-3 ~2 repeating_command_block 5 replace {auto:1b,TrackOutput:0b}},{id:MinecartCommandBlock,Command:"blockdata ~2 ~-3 ~0 {Command:"/scoreboard players tag @a[score_isSpri_min=50,rx=-30,rxm=-90] add isLookingUp {Inventory:[{Slot:102b,id:\\"minecraft:elytra\\"}]}"}"},{id:MinecartCommandBlock,Command:"blockdata ~3 ~-3 ~0 {Command:"/scoreboard objectives add isSpri dummy"}"},{id:MinecartCommandBlock,Command:"blockdata ~4 ~-3 ~0 {Command:"/scoreboard objectives add isSpr stat.sprintOneCm"}"},{id:MinecartCommandBlock,Command:"blockdata ~5 ~-3 ~0 {Command:"/execute @a[score_isSpr_min=1] ~ ~ ~ scoreboard players add @a[score_isSpr_min=1] isSpri 1"}"},{id:MinecartCommandBlock,Command:"blockdata ~2 ~-3 ~1 {Command:"/execute @a[score_isSpr=0] ~ ~ ~ scoreboard players set @a[score_isSpr=0] isSpri 0"}"},{id:MinecartCommandBlock,Command:"blockdata ~3 ~-3 ~1 {Command:"/scoreboard players set @a isSpr 0"}"},{id:MinecartCommandBlock,Command:"blockdata ~4 ~-3 ~1 {Command:"/tp @a[tag=isLookingUp] ~ ~3 ~"}"},{id:MinecartCommandBlock,Command:"blockdata ~5 ~-3 ~1 {Command:"/scoreboard players tag @a[tag=isLookingUp] add isFlying"}"},{id:MinecartCommandBlock,Command:"blockdata ~2 ~-3 ~2 {Command:"/scoreboard players tag @a[tag=isLookingUp] remove isLookingUp"}"},{id:MinecartCommandBlock,Command:"blockdata ~3 ~-3 ~2 {Command:"/tp @a[tag=isFlying] ~ ~0.2 ~"}"},{id:MinecartCommandBlock,Command:"blockdata ~4 ~-3 ~2 {Command:"/scoreboard players tag @a[tag=isFlying] remove isFlying {OnGround:1b}"}"},{id:MinecartCommandBlock,Command:setblock ~1 ~-2 ~ command_block 0 replace {Command:fill ~-1 ~0 ~ ~ ~2 ~ air}},{id:MinecartCommandBlock,Command:summon FallingSand ~1 ~-1 ~ {Time:1,Block:redstone_block}},{id:MinecartCommandBlock,Command:setblock ~ ~-3 ~2 command_block 4 replace {Command:fill ~2 ~0 ~-2 ~5 ~0 ~0 air}},{id:MinecartCommandBlock,Command:kill @e[type=MinecartCommandBlock,r=2]}]}]}]}
核心使用方式:
整体指令部分:
演示存档:
[groupid=546]Command Block Logic[/groupid]