2015年9月28日月曜日

【コマンドブロック】スプラトゥーンコマンド公開(3)ローラーの処理(コピペOK)【マインクラフト】

ローラーはジャンプ攻撃と通常攻撃があります。
ココには書きませんが、人参付きの棒で使った回数を記録するスコア(usedcarrotstick)をつくってください。
処理の内容は各方角と一致した時だけ処理を実行する内容です。
前々回使ったontimeスコアも登場します。ジャンプのタイミングを検知します。

リセット回路は回路とついていますが、タイミングをずらして実行してください。
過去記事にreset回路の一元化があるのでそちらを参照してください。

方位判定スコア(8)
北、北東、東、南東、南、南西、西、北西
1,2,3,4,5,6,7,8
scoreboard players set @a[rym=160,ry=-160] direction 1
scoreboard players set @a[rym=-155,ry=-115] direction 2
scoreboard players set @a[rym=-110,ry=-70] direction 3
scoreboard players set @a[rym=-65,ry=-25] direction 4
scoreboard players set @a[rym=-20,ry=20] direction 5
scoreboard players set @a[rym=25,ry=65] direction 6
scoreboard players set @a[rym=70,ry=110] direction 7
scoreboard players set @a[rym=115,ry=155] direction 8

ローラー>(24)
各方位処理(8x2)
(赤)
/execute @a[team=red,score_direction_min=1,score_usedcarrotstick_min=1,lm=1,score_ontime_min=2,score_ontime=6] ~ ~-1 ~-5 detect ~ ~-1 ~ minecraft:wool -1 fill ~2 ~5 ~1 ~-2 ~-1 ~0 minecraft:wool 1 replace minecraft:wool
/execute @a[team=red,score_direction_min=2,score_usedcarrotstick_min=1,lm=1,score_ontime_min=2,score_ontime=6] ~4 ~-1 ~-4 detect ~ ~-1 ~ minecraft:wool -1 fill ~-1 ~5 ~-1 ~1 ~-1 ~1 minecraft:wool 1 replace minecraft:wool
/execute @a[team=red,score_direction_min=3,score_usedcarrotstick_min=1,lm=1,score_ontime_min=2,score_ontime=6] ~5 ~-1 ~ detect ~ ~-1 ~ minecraft:wool -1 fill ~0 ~5 ~-2 ~1 ~-1 ~2 minecraft:wool 1 replace minecraft:wool
/execute @a[team=red,score_direction_min=4,score_usedcarrotstick_min=1,lm=1,score_ontime_min=2,score_ontime=6] ~4 ~-1 ~4 detect ~ ~-1 ~ minecraft:wool -1 fill ~-1 ~5 ~-1 ~1 ~-1 ~1 minecraft:wool 1 replace minecraft:wool
/execute @a[team=red,score_direction_min=5,score_usedcarrotstick_min=1,lm=1,score_ontime_min=2,score_ontime=6] ~ ~-1 ~5 detect ~ ~-1 ~ minecraft:wool -1 fill ~2 ~5 ~1 ~-2 ~-1 ~0 minecraft:wool 1 replace minecraft:wool
/execute @a[team=red,score_direction_min=6,score_usedcarrotstick_min=1,lm=1,score_ontime_min=2,score_ontime=6] ~-4 ~-1 ~4 detect ~ ~-1 ~ minecraft:wool -1 fill ~-1 ~5 ~-1 ~1 ~-1 ~1 minecraft:wool 1 replace minecraft:wool
/execute @a[team=red,score_direction_min=7,score_usedcarrotstick_min=1,lm=1,score_ontime_min=2,score_ontime=6] ~-5 ~-1 ~ detect ~ ~-1 ~ minecraft:wool -1 fill ~0 ~5 ~-2 ~1 ~-1 ~2 minecraft:wool 1 replace minecraft:wool
/execute @a[team=red,score_direction_min=8,score_usedcarrotstick_min=1,lm=1] ~-4 ~-1 ~-4 detect ~ ~-1 ~ minecraft:wool -1 fill ~-1 ~5 ~-1 ~1 ~-1 ~1 minecraft:wool 1 replace minecraft:wool

(青)
/execute @a[team=blue,score_direction_min=1,score_usedcarrotstick_min=1,lm=1,score_ontime_min=2,score_ontime=6] ~ ~-1 ~-5 detect ~ ~-1 ~ minecraft:wool -1 fill ~2 ~5 ~1 ~-2 ~-1 ~0 minecraft:wool 2 replace minecraft:wool
/execute @a[team=blue,score_direction_min=2,score_usedcarrotstick_min=1,lm=1,score_ontime_min=2,score_ontime=6] ~4 ~-1 ~-4 detect ~ ~-1 ~ minecraft:wool -1 fill ~-1 ~5 ~-1 ~1 ~-1 ~1 minecraft:wool 2 replace minecraft:wool
/execute @a[team=blue,score_direction_min=3,score_usedcarrotstick_min=1,lm=1,score_ontime_min=2,score_ontime=6] ~5 ~-1 ~ detect ~ ~-1 ~ minecraft:wool -1 fill ~0 ~5 ~-2 ~1 ~-1 ~2 minecraft:wool 2 replace minecraft:wool
/execute @a[team=blue,score_direction_min=4,score_usedcarrotstick_min=1,lm=1,score_ontime_min=2,score_ontime=6] ~4 ~-1 ~4 detect ~ ~-1 ~ minecraft:wool -1 fill ~-1 ~5 ~-1 ~1 ~-1 ~1 minecraft:wool 2 replace minecraft:wool
/execute @a[team=blue,score_direction_min=5,score_usedcarrotstick_min=1,lm=1,score_ontime_min=2,score_ontime=6] ~ ~-1 ~5 detect ~ ~-1 ~ minecraft:wool -1 fill ~2 ~5 ~1 ~-2 ~-1 ~0 minecraft:wool 2 replace minecraft:wool
/execute @a[team=blue,score_direction_min=6,score_usedcarrotstick_min=1,lm=1,score_ontime_min=2,score_ontime=6] ~-4 ~-1 ~4 detect ~ ~-1 ~ minecraft:wool -1 fill ~-1 ~5 ~-1 ~1 ~-1 ~1 minecraft:wool 2 replace minecraft:wool
/execute @a[team=blue,score_direction_min=7,score_usedcarrotstick_min=1,lm=1,score_ontime_min=2,score_ontime=6] ~-5 ~-1 ~ detect ~ ~-1 ~ minecraft:wool -1 fill ~0 ~5 ~-2 ~1 ~-1 ~2 minecraft:wool 2 replace minecraft:wool
/execute @a[team=blue,score_direction_min=8,score_usedcarrotstick_min=1,lm=1] ~-4 ~-1 ~-4 detect ~ ~-1 ~ minecraft:wool -1 fill ~-1 ~5 ~-1 ~1 ~-1 ~1 minecraft:wool 2 replace minecraft:wool
経験値処理(3):
(共通)
/xp -1L @a[score_usedcarrotstick_min=1]
/xp -3L @a[score_usedcarrotstick_min=1,score_ontime_min=2,score_ontime=6]
/execute @a[score_usedcarrotstick_min=1,lm=0] ~ ~ ~ /say インク残量不足 @a[score_usedcarrotstick_min=1,l=0]

通常攻撃処理(2x2)
(赤)
/execute @a[team=red,score_usedcarrotstick_min=1,lm=1] ~ ~ ~ detect ~ ~-1 ~ minecraft:wool -1 fill ~1 ~ ~1 ~-1 ~-1 ~-1 minecraft:wool 1 replace minecraft:wool
/execute @a[team=red,score_usedcarrotstick_min=1,lm=1] ~ ~ ~ detect ~ ~-1 ~ minecraft:wool -1  /effect @a[team=blue,r=3] minecraft:instant_damage 1 0

(青)
/execute @a[team=blue,score_usedcarrotstick_min=1,lm=1] ~ ~ ~ detect ~ ~-1 ~ minecraft:wool -1 fill ~1 ~ ~1 ~-1 ~-1 ~-1 minecraft:wool 2 replace minecraft:wool
/execute @a[team=blue,score_usedcarrotstick_min=1,lm=1] ~ ~ ~ detect ~ ~-1 ~ minecraft:wool -1  /effect @a[team=red,r=3] minecraft:instant_damage 1 0

識別子:なし

リセット回路(1):
/scoreboard players reset @a usedcarrotstick
床上処理と併用箇所
/execute @a ~ ~ ~ detect ~ ~-1 ~ minecraft:wool 0 /scoreboard players set @a[r=1,c=1] ontime 0
/execute @a[team=red] ~ ~ ~ detect ~ ~-1 ~ minecraft:wool 1 /scoreboard players set @a[team=red,r=1,c=1] ontime 0
/execute @a[team=blue] ~ ~ ~ detect ~ ~-1 ~ minecraft:wool 2 /scoreboard players set @a[team=blue,r=1,c=1] ontime 0


前: 【コマンドブロック】スプラトゥーンコマンド公開(2)イカモードの基本処理(コピペOK!)【マインクラフト】


にほんブログ村 ゲームブログ Minecraftへ

0 件のコメント:

フィード