Skip to content

Commit

Permalink
オープニング攻撃 実装
Browse files Browse the repository at this point in the history
  • Loading branch information
EllaCoat committed Aug 15, 2024
1 parent df21e82 commit ae131a4
Show file tree
Hide file tree
Showing 23 changed files with 252 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,9 @@
#declare tag AV.DimSwordDisplay
#declare tag AV.ShockWave
#declare tag AV.CriticalHit
#declare tag AV.CriticalOpening

#> val
# @within function asset:mob/0391.axia_first/**
#declare score_holder $AV.Temp
#declare score_holder $AV.Loop
Original file line number Diff line number Diff line change
Expand Up @@ -48,3 +48,6 @@

# 被弾アニメーション2
execute if score @s AV.AnimationNum matches 991 run function asset:mob/0391.axia_first/ai/animation/99_1_damaged_2/

# オープニングアタック
execute if score @s AV.AnimationNum matches 1000 run function asset:mob/0391.axia_first/ai/animation/100_0_opening/
Original file line number Diff line number Diff line change
@@ -0,0 +1,101 @@
#> asset:mob/0391.axia_first/ai/animation/100_0_opening/
#
# オープニング アニメーション
#
# @within function asset:mob/0391.axia_first/ai/animation/

# 対象プレイヤー保存
execute if score @s AV.AnimationTick matches 1 run scoreboard players operation @s AV.UUID = @p[tag=!PlayerShouldInvulnerable,distance=..100] UserID

# 近くのプレイヤーの方を向く
# 一部の時間のみ向く処理を入れる
tag @s add AV.Temp.This
scoreboard players operation $AV.Temp AV.UUID = @s AV.UUID
execute if score @s AV.AnimationTick matches 153..159 if predicate api:global_vars/difficulty/max/normal as @a if score @s UserID = $AV.Temp AV.UUID run function asset:mob/0391.axia_first/ai/general/2.rotate
execute if score @s AV.AnimationTick matches 153..159 if predicate api:global_vars/difficulty/min/hard as @a if score @s UserID = $AV.Temp AV.UUID run function asset:mob/0391.axia_first/ai/animation/7_0_zangekihou/rotate
execute if score @s AV.AnimationTick matches 178..185 if predicate api:global_vars/difficulty/max/normal as @a if score @s UserID = $AV.Temp AV.UUID run function asset:mob/0391.axia_first/ai/general/2.rotate
execute if score @s AV.AnimationTick matches 178..185 if predicate api:global_vars/difficulty/min/hard as @a if score @s UserID = $AV.Temp AV.UUID run function asset:mob/0391.axia_first/ai/animation/7_0_zangekihou/rotate
execute if score @s AV.AnimationTick matches 230..243 as @p[tag=!PlayerShouldInvulnerable,distance=..100] run function asset:mob/0391.axia_first/ai/general/2.rotate
execute if score @s AV.AnimationTick matches 244..253 if predicate api:global_vars/difficulty/min/hard if entity @p[distance=..100] run function asset:mob/0391.axia_first/ai/animation/3_0_triple_slash/predict/
scoreboard players reset $AV.Temp AV.UUID
tag @s remove AV.Temp.This

# アニメーション再生

Check failure on line 23 in Asset/data/asset/functions/mob/0391.axia_first/ai/animation/100_0_opening/.mcfunction

View workflow job for this annotation

GitHub Actions / lint

Failed to resolve namespaced ID “animated_java:axia/animations/14_0_opening_attack/play” in cache category “function” (rule: “strictFunctionCheck”)
execute if score @s AV.AnimationTick matches 1 as @e[type=item_display,tag=AV.Root.This,distance=..100] run function animated_java:axia/animations/14_0_opening_attack/play

# アニメーション停止

Check failure on line 26 in Asset/data/asset/functions/mob/0391.axia_first/ai/animation/100_0_opening/.mcfunction

View workflow job for this annotation

GitHub Actions / lint

Failed to resolve namespaced ID “animated_java:axia/animations/14_0_opening_attack/pause” in cache category “function” (rule: “strictFunctionCheck”)
execute if score @s AV.AnimationTick matches 1 as @e[type=item_display,tag=AV.Root.This,distance=..100] run function animated_java:axia/animations/14_0_opening_attack/pause

# アニメーション再開

Check failure on line 29 in Asset/data/asset/functions/mob/0391.axia_first/ai/animation/100_0_opening/.mcfunction

View workflow job for this annotation

GitHub Actions / lint

Failed to resolve namespaced ID “animated_java:axia/animations/14_0_opening_attack/resume” in cache category “function” (rule: “strictFunctionCheck”)
execute if score @s AV.AnimationTick matches 71 as @e[type=item_display,tag=AV.Root.This,distance=..100] run function animated_java:axia/animations/14_0_opening_attack/resume

# アニメーション終了処理
execute if score @s AV.AnimationTick matches 281 run function asset:mob/0391.axia_first/ai/animation/100_0_opening/end

# クリティカルヒット 配置
execute if score @s AV.AnimationTick matches 1 run function asset:mob/0391.axia_first/ai/projectile/critical/0.summon
execute if score @s AV.AnimationTick matches 1 run tag @e[tag=AV.CriticalHit,distance=..64] add AV.CriticalOpening

# 衝撃波 配置
execute if score @s AV.AnimationTick matches 81 at @e[type=marker,tag=AV.Marker.SummonPoint,distance=..100,limit=1] if predicate api:global_vars/difficulty/min/hard run function asset:mob/0391.axia_first/ai/animation/100_0_opening/wave/1
execute if score @s AV.AnimationTick matches 85 at @e[type=marker,tag=AV.Marker.SummonPoint,distance=..100,limit=1] run function asset:mob/0391.axia_first/ai/animation/100_0_opening/wave/2
execute if score @s AV.AnimationTick matches 89 at @e[type=marker,tag=AV.Marker.SummonPoint,distance=..100,limit=1] if predicate api:global_vars/difficulty/min/hard run function asset:mob/0391.axia_first/ai/animation/100_0_opening/wave/3
execute if score @s AV.AnimationTick matches 105 at @e[type=marker,tag=AV.Marker.SummonPoint,distance=..100,limit=1] run function asset:mob/0391.axia_first/ai/animation/100_0_opening/wave/4
execute if score @s AV.AnimationTick matches 109 at @e[type=marker,tag=AV.Marker.SummonPoint,distance=..100,limit=1] if predicate api:global_vars/difficulty/min/hard run function asset:mob/0391.axia_first/ai/animation/100_0_opening/wave/5

# 斬撃砲
execute positioned ^ ^1.25 ^ if score @s AV.AnimationTick matches 168 run function asset:mob/0391.axia_first/ai/projectile/zangekihou/1.start
execute positioned ^ ^1.25 ^ if score @s AV.AnimationTick matches 194 run function asset:mob/0391.axia_first/ai/projectile/zangekihou/1.start

# 予告線
execute if score @s AV.AnimationTick matches 153 run function asset:mob/0391.axia_first/ai/animation/100_0_opening/announce_line
execute if score @s AV.AnimationTick matches 179 run function asset:mob/0391.axia_first/ai/animation/100_0_opening/announce_line

# TP
execute if score @s AV.AnimationTick matches 232 at @s run tp @s ^ ^0.2 ^ ~ ~
execute if score @s AV.AnimationTick matches 233 at @s run tp @s ^ ^0.3 ^ ~ ~
execute if score @s AV.AnimationTick matches 234 at @s run tp @s ^ ^0.4 ^ ~ ~
execute if score @s AV.AnimationTick matches 235 at @s run tp @s ^ ^0.5 ^ ~ ~
execute if score @s AV.AnimationTick matches 236 at @s run tp @s ^ ^0.4 ^ ~ ~
execute if score @s AV.AnimationTick matches 237 at @s run tp @s ^ ^0.3 ^ ~ ~
execute if score @s AV.AnimationTick matches 238 at @s run tp @s ^ ^0.2 ^ ~ ~
execute if score @s AV.AnimationTick matches 239 at @s run tp @s ^ ^0.1 ^ ~ ~

execute if score @s AV.AnimationTick matches 246 at @s run tp @s ^ ^-0.1 ^ ~ ~
execute if score @s AV.AnimationTick matches 247 at @s run tp @s ^ ^-0.2 ^ ~ ~
execute if score @s AV.AnimationTick matches 248 at @s run tp @s ^ ^-0.3 ^ ~ ~
execute if score @s AV.AnimationTick matches 249 at @s run tp @s ^ ^-0.4 ^ ~ ~
execute if score @s AV.AnimationTick matches 250 at @s run tp @s ^ ^-0.5 ^ ~ ~
execute if score @s AV.AnimationTick matches 251 at @s run tp @s ^ ^-0.4 ^ ~ ~
execute if score @s AV.AnimationTick matches 252 at @s run tp @s ^ ^-0.3 ^ ~ ~
execute if score @s AV.AnimationTick matches 253 at @s run tp @s ^ ^-0.2 ^ ~ ~

# 中央ダメージエリア
execute if score @s AV.AnimationTick matches 232 at @s run function asset:mob/0391.axia_first/ai/projectile/critical/0.summon

# 衝撃波召喚
execute if score @s AV.AnimationTick matches 253 at @s run function asset:mob/0391.axia_first/ai/animation/9_0_dimension_slash/wave/1
execute if score @s AV.AnimationTick matches 256 at @s run function asset:mob/0391.axia_first/ai/animation/9_0_dimension_slash/wave/2
execute if score @s AV.AnimationTick matches 259 at @s run function asset:mob/0391.axia_first/ai/animation/9_0_dimension_slash/wave/3
execute if score @s AV.AnimationTick matches 262 at @s run function asset:mob/0391.axia_first/ai/animation/9_0_dimension_slash/wave/4

# 自機狙い
tag @s add AV.Temp.This
execute if score @s AV.AnimationTick matches 253 as @a[tag=!PlayerShouldInvulnerable,distance=..100,sort=random,limit=4] at @s run function asset:mob/0391.axia_first/ai/projectile/sword/0.summon
execute if score @s AV.AnimationTick matches 268 as @a[tag=!PlayerShouldInvulnerable,distance=..100,sort=random,limit=4] at @s run function asset:mob/0391.axia_first/ai/projectile/sword/0.summon
execute if score @s AV.AnimationTick matches 281 if predicate api:global_vars/difficulty/min/hard as @a[tag=!PlayerShouldInvulnerable,distance=..100,sort=random,limit=4] at @s run function asset:mob/0391.axia_first/ai/projectile/sword/0.summon

# ランダム撃ち
execute if score @s AV.AnimationTick matches 256 if predicate api:global_vars/difficulty/min/hard as @a[tag=!PlayerShouldInvulnerable,distance=..100,sort=random,limit=2] at @s run function asset:mob/0391.axia_first/ai/animation/9_0_dimension_slash/sword/normal
execute if score @s AV.AnimationTick matches 256 if predicate api:global_vars/difficulty/min/hard as @a[tag=!PlayerShouldInvulnerable,distance=..100,sort=random,limit=2] at @s run function asset:mob/0391.axia_first/ai/animation/9_0_dimension_slash/sword/normal
execute if score @s AV.AnimationTick matches 253 if predicate api:global_vars/difficulty/min/hard as @a[tag=!PlayerShouldInvulnerable,distance=..100,sort=random,limit=2] at @s run function asset:mob/0391.axia_first/ai/animation/9_0_dimension_slash/sword/normal
execute if score @s AV.AnimationTick matches 253 if predicate api:global_vars/difficulty/min/hard as @a[tag=!PlayerShouldInvulnerable,distance=..100,sort=random,limit=2] at @s run function asset:mob/0391.axia_first/ai/animation/9_0_dimension_slash/sword/normal
execute if score @s AV.AnimationTick matches 259 if predicate api:global_vars/difficulty/min/hard as @a[tag=!PlayerShouldInvulnerable,distance=..100,sort=random,limit=2] at @s run function asset:mob/0391.axia_first/ai/animation/9_0_dimension_slash/sword/normal
execute if score @s AV.AnimationTick matches 259 if predicate api:global_vars/difficulty/min/hard as @a[tag=!PlayerShouldInvulnerable,distance=..100,sort=random,limit=2] at @s run function asset:mob/0391.axia_first/ai/animation/9_0_dimension_slash/sword/normal
execute if score @s AV.AnimationTick matches 262 if predicate api:global_vars/difficulty/min/hard as @a[tag=!PlayerShouldInvulnerable,distance=..100,sort=random,limit=2] at @s run function asset:mob/0391.axia_first/ai/animation/9_0_dimension_slash/sword/normal
execute if score @s AV.AnimationTick matches 262 if predicate api:global_vars/difficulty/min/hard as @a[tag=!PlayerShouldInvulnerable,distance=..100,sort=random,limit=2] at @s run function asset:mob/0391.axia_first/ai/animation/9_0_dimension_slash/sword/normal
execute if score @s AV.AnimationTick matches 265 if predicate api:global_vars/difficulty/min/hard as @a[tag=!PlayerShouldInvulnerable,distance=..100,sort=random,limit=2] at @s run function asset:mob/0391.axia_first/ai/animation/9_0_dimension_slash/sword/normal
execute if score @s AV.AnimationTick matches 265 if predicate api:global_vars/difficulty/min/hard as @a[tag=!PlayerShouldInvulnerable,distance=..100,sort=random,limit=2] at @s run function asset:mob/0391.axia_first/ai/animation/9_0_dimension_slash/sword/normal
execute if score @s AV.AnimationTick matches 268 if predicate api:global_vars/difficulty/min/hard as @a[tag=!PlayerShouldInvulnerable,distance=..100,sort=random,limit=2] at @s run function asset:mob/0391.axia_first/ai/animation/9_0_dimension_slash/sword/normal
execute if score @s AV.AnimationTick matches 268 if predicate api:global_vars/difficulty/min/hard as @a[tag=!PlayerShouldInvulnerable,distance=..100,sort=random,limit=2] at @s run function asset:mob/0391.axia_first/ai/animation/9_0_dimension_slash/sword/normal
tag @s remove AV.Temp.This
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#> asset:mob/0391.axia_first/ai/animation/100_0_opening/announce_line
#
# 予告線
#
# @within function asset:mob/0391.axia_first/ai/animation/100_0_opening/

execute anchored eyes run summon item_display ^ ^ ^2 {interpolation_duration:0,teleport_duration:0,Tags:["AV.AnnounceInit"],brightness:{sky:15,block:15},transformation:{left_rotation:[0f,0f,0.383f,0.924f],right_rotation:[0f,0f,0f,1f],translation:[0f,0f,13.5f],scale:[0.1f,0.1f,25f]},item:{id:"air",Count:1b}}

execute anchored eyes positioned ^ ^ ^2 as @e[tag=AV.AnnounceInit,distance=..0.1] run tp @s ^ ^ ^ ~ ~

execute anchored eyes positioned ^ ^ ^2 as @e[tag=AV.AnnounceInit,distance=..0.1] run function asset:mob/0391.axia_first/ai/projectile/announce_line/1.init.m {Num:-15}
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#> asset:mob/0391.axia_first/ai/animation/100_0_opening/end
#
# 終了処理
#
# @within function asset:mob/0391.axia_first/ai/animation/100_0_opening/

# デバッグ用 アニメーションループ
scoreboard players set @s AV.AnimationNum 1000
scoreboard players set @s AV.AnimationTick 0
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#> asset:mob/0391.axia_first/ai/animation/100_0_opening/wave/1
#
# 衝撃波 1段目 配置
#
# @within function asset:mob/0391.axia_first/ai/animation/100_0_opening/

execute positioned ^7 ^ ^7 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^7 ^ ^ run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^7 ^ ^-7 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^ ^ ^7 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^ ^ ^-7 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^-7 ^ ^7 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^-7 ^ ^ run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^-7 ^ ^-7 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
#> asset:mob/0391.axia_first/ai/animation/100_0_opening/wave/2
#
# 衝撃波 2段目 配置
#
# @within function asset:mob/0391.axia_first/ai/animation/100_0_opening/

execute positioned ^14 ^ ^14 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^14 ^ ^7 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^14 ^ ^ run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^14 ^ ^-7 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^14 ^ ^-14 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^-14 ^ ^14 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^-14 ^ ^7 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^-14 ^ ^ run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^-14 ^ ^-7 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^-14 ^ ^-14 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^7 ^ ^14 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^ ^ ^14 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^-7 ^ ^14 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^7 ^ ^-14 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^ ^ ^-14 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^-7 ^ ^-14 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
#> asset:mob/0391.axia_first/ai/animation/100_0_opening/wave/3
#
# 衝撃波 3段目 配置
#
# @within function asset:mob/0391.axia_first/ai/animation/100_0_opening/

execute positioned ^21 ^ ^7 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^21 ^ ^ run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^21 ^ ^-7 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^-21 ^ ^7 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^-21 ^ ^ run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^-21 ^ ^-7 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^7 ^ ^21 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^ ^ ^21 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^-7 ^ ^21 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^7 ^ ^-21 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^ ^ ^-21 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^-7 ^ ^-21 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
#> asset:mob/0391.axia_first/ai/animation/100_0_opening/wave/4
#
# 衝撃波 4段目 配置
#
# @within function asset:mob/0391.axia_first/ai/animation/100_0_opening/

execute positioned ^10.5 ^ ^10.5 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^10.5 ^ ^3.5 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^10.5 ^ ^-3.5 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^10.5 ^ ^-10.5 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^-10.5 ^ ^10.5 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^-10.5 ^ ^3.5 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^-10.5 ^ ^-3.5 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^-10.5 ^ ^-10.5 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^3.5 ^ ^10.5 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^-3.5 ^ ^10.5 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^3.5 ^ ^-10.5 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
execute positioned ^-3.5 ^ ^-10.5 run function asset:mob/0391.axia_first/ai/projectile/shock_wave/0.summon
Loading

0 comments on commit ae131a4

Please sign in to comment.