About
位置 (-1920,9,-191)
呼び出し元 毎tick実行するコマンド群2
分岐先 習得スキル取得
レベルアップ時のスコアボードの書き換えや、新しいスキルの取得への分岐などを行う。
コマンド群
| No. | コマンド |
|---|---|
| 1 | /scoreboard players add @a[score_ExpToLevel=0,score_Level=49] Level 1 |
| 2 | /scoreboard players add @a[score_ExpToLevel=0] MPMax 1 |
| 3 | /execute @a[score_ExpToLevel=0] ~ ~ ~ /scoreboard players operation @a[c=1] MP = @a[c=1] MPMax |
| 4 | /scoreboard players set @a[score_ExpToLevel=0] MPMaxFlag 1 |
| 5 | /execute @a[score_ExpToLevel=0] ~ ~ ~ /scoreboard players operation @a[c=1] HPMax = @a[c=1] MPMax |
| 6 | /scoreboard players operation @a[score_ExpToLevel=0] HPMax /= #8 Const |
| 7 | /scoreboard players set @a[score_HPMax_min=51] HPMax 50 |
| 8 | /scoreboard players set @a[score_ExpToLevel=0] CoolTickSpan -100 |
| 9 | /execute @a[score_ExpToLevel=0] ~ ~ ~ /scoreboard players operation @a[c=1] CoolTickSpan += @a[c=1] Level |
| 10 | /execute @a[score_ExpToLevel=0] ~ ~ ~ /scoreboard players operation @a[c=1] MPIncrement = @a[c=1] MPMax |
| 11 | /scoreboard players operation @a[score_ExpToLevel=0] MPIncrement /= #50 Const |
| 12 | /scoreboard players operation @a[score_ExpToLevel=0] MPIncrement += #3 Const |
| 13 | /execute @a[score_ExpToLevel=0] ~ ~ ~ /playsound entity.player.levelup master @a[r=16] ~ ~ ~ 2 0.7 0 |
| 14 | /execute @a[score_ExpToLevel=0] ~ ~ ~ /particle happyVillager ~ ~ ~ 1 2 1 0.001 100 normal |
| 15 | /execute @a[score_ExpToLevel=0] ~ ~ ~ /summon FireworksRocketEntity ~ ~ ~ {LifeTime:10,FireworksItem:{id:minecraft:fireworks,Count:1b,tag:{Fireworks:{Explosions:[{Type:1b,Flicker:true,Trail:true,Colors:[16752934],FadeColors:[16777215]},{Type:0b,Flicker:false,Trail:false,Colors:[16715021,16777215],FadeColors:[16777215]}]}}}} |
| 16 | /title @a[score_ExpToLevel=0] times 5 100 20 |
| 17 | /title @a[score_ExpToLevel=0] subtitle [{“text”:”現在のレベル : “,”italic”:”true”},{“score”:{“name”:”*”,”objective”:”Level”},”bold”:”true”,”italic”:”false”}] |
| 18 | /title @a[score_ExpToLevel=0] title {“text”:”LEVEL UP !”,”color”:”green”,”bold”:”true”} |
| 19 | /scoreboard players tag @a[score_ExpToLevel=0,score_Level_min=1,score_Level=50,score_NextExp=349] add ShowNewSkill |
| 20 | /clone -1920 ~1 ~ -1920 ~6 ~ -1920 ~1 ~ filtered force minecraft:command_block 5 #習得スキル取得 |
| 21 | /scoreboard players set #ReserveShowSkill Global 1 |
| 22 | /scoreboard players set @a[score_ExpToLevel=0] RefreshHPMax 3 |
| 23 | /execute @a[score_ExpToLevel=0] ~ ~ ~ /scoreboard players operation @a[c=1] NextExp = @a[c=1] Level |
| 24 | /scoreboard players operation @a[score_ExpToLevel=0] NextExp *= #ExpMul Const |
| 25 | /execute @a[score_ExpToLevel=0] ~ ~ ~ /scoreboard players operation @a[c=1] ExpToLevel += @a[c=1] NextExp |
詳細
ExpToLevelが0以下で、Levelが49以下であるプレイヤーのLevelを1に設定ExpToLevelが0以下であるプレイヤーのMPMaxを1に設定、MPにMPMaxを代入、MPMaxFlagを1に設定、HPMaxにMPMaxを代入、HPMaxに8で割った時の商を代入HPMaxが51以上であるプレイヤーのHPMaxを50に設定ExpTolevelが0以下であるプレイヤーのCoolTickSpanを-100に設定、CoolTickSpanにLevelを足し合わせ、MPInvrementにMPMaxを代入ExpTolevelが0以下であるプレイヤーのMPIncrementに50で割った時の商を代入、MPIncrementに3を足すExpTolevelが0以下であるプレイヤーの座標で演出の実行ExpToLevelが0以上、Levelが1以上50以下、NextExpが349以下であるプレイヤーにShowNewSkillを付与- (-1920,10,-191)から(-1920,15,-191)にある習得スキル取得を実行
#ReserveShowSkillのGlobalを1に設定ExpToLevelが0以下であるプレイヤーのRefreshHPMaxを3に設定、NextExpにLevelを代入、NextExpに7との積を代入、ExpToLevelにNextExpを足し合わせる