diff --git a/README.md b/README.md index eeded0c..1d910c0 100644 --- a/README.md +++ b/README.md @@ -14,11 +14,10 @@ - `数据包 v2.1.x` 支持 `Minecraft 1.17.x-1.18.x` - `数据包 v2.0.x` 支持 `Minecraft 1.16.3-1.16.5` 2. 前往[发行页面](https://gitee.com/harvey-husky/FZ-sDatapack/releases)下载对应MC版本的数据包 -3. 从zip文件的 `scripts` 目录中挑选你需要的 `.sc` 文件 -4. 将数据包 `zip` 文件放入 `world/datapacks` 中(在客户端位于 `.minecraft/saves/<存档名>/datapacks`) -5. (可选)下载并安装 [Carpet Mod **1.4.24**](https://github.com/gnembon/fabric-carpet/releases) 或以上版本 -6. (可选)从数据包 `zip` 文件的 `scripts` 目录中解压 `.sc` 文件,将其放入 `world/scripts` 中(在客户端位于 `.minecraft/saves/<存档名>/scripts` ) -7. 执行 `reload` 指令(或重新打开存档) +3. 将数据包 `zip` 文件放入 `world/datapacks` 中(在客户端位于 `.minecraft/saves/<存档名>/datapacks`) +4. (可选)下载并安装 [Carpet Mod **1.4.24**](https://github.com/gnembon/fabric-carpet/releases) 或以上版本 +5. (可选)从数据包 `zip` 文件的 `scripts` 目录中解压 `.sc` 文件,将其放入 `world/scripts` 中(在客户端位于 `.minecraft/saves/<存档名>/scripts` ) +6. 执行 `reload` 指令(或重新打开存档) # FZ生存数据包 3.0 diff --git a/data/admin.fzsd/functions/admin.mcfunction b/data/admin.fzsd/functions/admin.mcfunction index 8784294..9eb5cfd 100644 --- a/data/admin.fzsd/functions/admin.mcfunction +++ b/data/admin.fzsd/functions/admin.mcfunction @@ -35,4 +35,4 @@ tellraw @s [{"text": "上一出生点:"}, [{"text": "", "color": "dark_gray"}, tellraw @s [{"text": "计分板:"}, [{"text": "", "color": "dark_gray"}, [{"text": "[", "clickEvent": {"action": "run_command", "value": "/function #fzsd:module/scoreboard/install"}, "hoverEvent": {"action": "show_text", "contents": {"text": "安装", "color": "dark_green"}}}, {"text": "安装", "color": "dark_green"}, {"text": "]"}], [{"text": "[", "clickEvent": {"action": "run_command", "value": "/function #fzsd:module/scoreboard/uninstall"}, "hoverEvent": {"action": "show_text", "contents": {"text": "卸载", "color": "dark_red"}}}, {"text": "卸载", "color": "dark_red"}, {"text": "]"}]]] -tellraw @s [{"text": "扫地机:"}, [{"text": "", "color": "dark_gray"}, [{"text": "[", "clickEvent": {"action": "run_command", "value": "/function #fzsd:module/sweeper/install"}, "hoverEvent": {"action": "show_text", "contents": {"text": "安装", "color": "dark_green"}}}, {"text": "安装", "color": "dark_green"}, {"text": "]"}], [{"text": "[", "clickEvent": {"action": "run_command", "value": "/function #fzsd:module/sweeper/uninstall"}, "hoverEvent": {"action": "show_text", "contents": {"text": "卸载", "color": "dark_red"}}}, {"text": "卸载", "color": "dark_red"}, {"text": "]"}]]] \ No newline at end of file +tellraw @s [{"text": "扫地机:"}, [{"text": "", "color": "dark_gray"}, [{"text": "[", "clickEvent": {"action": "run_command", "value": "/function #fzsd:module/sweeper/install"}, "hoverEvent": {"action": "show_text", "contents": {"text": "安装", "color": "dark_green"}}}, {"text": "安装", "color": "dark_green"}, {"text": "]"}], [{"text": "[", "clickEvent": {"action": "run_command", "value": "/function #fzsd:module/sweeper/uninstall"}, "hoverEvent": {"action": "show_text", "contents": {"text": "卸载", "color": "dark_red"}}}, {"text": "卸载", "color": "dark_red"}, {"text": "]"}],[{"text": "[", "clickEvent": {"action": "run_command", "value": "/data modify storage fzsd:module fzsd.sweeper.extra_interval set value 1b"}},{"text": "显示额外时间","color": "green"},{"text": "]"}],[{"text": "[", "clickEvent": {"action": "run_command", "value": "/data modify storage fzsd:module fzsd.sweeper.extra_interval set value 0b"}},{"text": "隐藏额外时间","color": "red"},{"text": "]"}]]] \ No newline at end of file diff --git a/data/fzsd/functions/module/sweeper/clear.mcfunction b/data/fzsd/functions/module/sweeper/clear.mcfunction index 12f5a12..e2afcd3 100644 --- a/data/fzsd/functions/module/sweeper/clear.mcfunction +++ b/data/fzsd/functions/module/sweeper/clear.mcfunction @@ -11,5 +11,13 @@ schedule clear fzsd:module/sweeper/timer/1min schedule clear fzsd:module/sweeper/timer/2min schedule clear fzsd:module/sweeper/timer/3min schedule clear fzsd:module/sweeper/timer/4min +schedule clear fzsd:module/sweeper/timer/5min +schedule clear fzsd:module/sweeper/timer/6min +schedule clear fzsd:module/sweeper/timer/7min +schedule clear fzsd:module/sweeper/timer/8min +schedule clear fzsd:module/sweeper/timer/9min +schedule clear fzsd:module/sweeper/timer/10min +schedule clear fzsd:module/sweeper/timer/12min +schedule clear fzsd:module/sweeper/timer/15min bossbar set fzsd:sweeper visible false bossbar set fzsd:sweeper value 0 \ No newline at end of file diff --git a/data/fzsd/functions/module/sweeper/interactor/display_0.mcfunction b/data/fzsd/functions/module/sweeper/interactor/display_0.mcfunction index 27a4184..5ea3082 100644 --- a/data/fzsd/functions/module/sweeper/interactor/display_0.mcfunction +++ b/data/fzsd/functions/module/sweeper/interactor/display_0.mcfunction @@ -9,4 +9,5 @@ tellraw @s[tag=fzsd.ignore_sweeper_sound] [{"text": "- 音效:"}, [{"text": "[ tellraw @s[tag=!fzsd.ignore_sweeper_message] [{"text": "- 消息:"}, [{"text": "[", "color": "gray", "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set 3600"}}, {"text": "已开启", "color": "green"}, {"text": "]", "color": "gray"}]] tellraw @s[tag=fzsd.ignore_sweeper_message] [{"text": "- 消息:"}, [{"text": "[", "color": "gray", "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set 3601"}}, {"text": "已关闭", "color": "red"}, {"text": "]", "color": "gray"}]] -tellraw @s [{"text": "- 开关:"}, [{"text": "[", "color": "dark_gray", "hoverEvent": {"action": "show_text", "contents": {"text": "关", "color": "dark_red"}}, "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -3000"}}, {"text": "关", "color": "red"}, {"text": "]"}], [{"text": "[", "color": "gray", "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -3300"}}, {"text": "清理一次", "color": "aqua"}, {"text": "]", "color": "gray"}], [{"text": "[", "hoverEvent": {"action": "show_text", "contents": {"text": "10s", "color": "#aa0000"}}, "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -3010"}}, {"text": "10s", "color": "#aa0000"}, {"text": "]"}], [{"text": "[", "hoverEvent": {"action": "show_text", "contents": {"text": "30s", "color": "#da7924"}}, "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -3030"}}, {"text": "30s", "color": "#da7924"}, {"text": "]"}], [{"text": "[", "hoverEvent": {"action": "show_text", "contents": {"text": "1min", "color": "#ffe34c"}}, "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -3060"}}, {"text": "1min", "color": "#ffe34c"}, {"text": "]"}], [{"text": "[", "hoverEvent": {"action": "show_text", "contents": {"text": "2min", "color": "#e3ff50"}}, "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -3120"}}, {"text": "2min", "color": "#e3ff50"}, {"text": "]"}], [{"text": "[", "hoverEvent": {"action": "show_text", "contents": {"text": "3min", "color": "#81d42c"}}, "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -3180"}}, {"text": "3min", "color": "#81d42c"}, {"text": "]"}], [{"text": "[", "hoverEvent": {"action": "show_text", "contents": {"text": "4min", "color": "#00aa00"}}, "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -3240"}}, {"text": "4min", "color": "#00aa00"}, {"text": "]"}]] \ No newline at end of file +tellraw @s [{"text": "- 开关:"}, [{"text": "[", "color": "dark_gray", "hoverEvent": {"action": "show_text", "contents": {"text": "关", "color": "dark_red"}}, "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -3000"}}, {"text": "关", "color": "red"}, {"text": "]"}], [{"text": "[", "color": "gray", "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -3300"}}, {"text": "清理一次", "color": "aqua"}, {"text": "]", "color": "gray"}], [{"text": "[", "hoverEvent": {"action": "show_text", "contents": {"text": "10s", "color": "#aa0000"}}, "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -4010"}}, {"text": "10s", "color": "#aa0000"}, {"text": "]"}], [{"text": "[", "hoverEvent": {"action": "show_text", "contents": {"text": "30s", "color": "#da7924"}}, "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -4030"}}, {"text": "30s", "color": "#da7924"}, {"text": "]"}], [{"text": "[", "hoverEvent": {"action": "show_text", "contents": {"text": "1min", "color": "#ffe34c"}}, "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -4060"}}, {"text": "1min", "color": "#ffe34c"}, {"text": "]"}], [{"text": "[", "hoverEvent": {"action": "show_text", "contents": {"text": "2min", "color": "#e3ff50"}}, "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -4120"}}, {"text": "2min", "color": "#e3ff50"}, {"text": "]"}], [{"text": "[", "hoverEvent": {"action": "show_text", "contents": {"text": "3min", "color": "#81d42c"}}, "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -4180"}}, {"text": "3min", "color": "#81d42c"}, {"text": "]"}], [{"text": "[", "hoverEvent": {"action": "show_text", "contents": {"text": "4min", "color": "#00aa00"}}, "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -4240"}}, {"text": "4min", "color": "#00aa00"}, {"text": "]"}]] +execute if data storage fzsd:module fzsd.sweeper{extra_interval:1b} run tellraw @s [{"text": "- 额外:"}, [{"text": "[", "hoverEvent": {"action": "show_text", "contents": {"text": "5min", "color": "#aa0000"}}, "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -4300"}}, {"text": "5min", "color": "#aa0000"}, {"text": "]"}], [{"text": "[", "hoverEvent": {"action": "show_text", "contents": {"text": "6min", "color": "#da7924"}}, "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -4360"}}, {"text": "6min", "color": "#da7924"}, {"text": "]"}], [{"text": "[", "hoverEvent": {"action": "show_text", "contents": {"text": "7min", "color": "#ffe34c"}}, "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -4420"}}, {"text": "7min", "color": "#ffe34c"}, {"text": "]"}], [{"text": "[", "hoverEvent": {"action": "show_text", "contents": {"text": "8min", "color": "#e3ff50"}}, "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -4480"}}, {"text": "8min", "color": "#e3ff50"}, {"text": "]"}], [{"text": "[", "hoverEvent": {"action": "show_text", "contents": {"text": "9min", "color": "#81d42c"}}, "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -4540"}}, {"text": "9min", "color": "#81d42c"}, {"text": "]"}], [{"text": "[", "hoverEvent": {"action": "show_text", "contents": {"text": "10min", "color": "#00aa00"}}, "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -4600"}}, {"text": "10min", "color": "#00aa00"}, {"text": "]"}],[{"text": "[", "hoverEvent": {"action": "show_text", "contents": {"text": "12min", "color": "light_purple"}}, "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -4720"}}, {"text": "12min", "color": "light_purple"}, {"text": "]"}],[{"text": "[", "hoverEvent": {"action": "show_text", "contents": {"text": "15min", "color": "dark_purple"}}, "clickEvent": {"action": "run_command", "value": "/trigger fzsd.module.interactor.trigger set -4900"}}, {"text": "15min", "color": "dark_purple"}, {"text": "]"}]] \ No newline at end of file diff --git a/data/fzsd/functions/module/sweeper/interactor/on_click.mcfunction b/data/fzsd/functions/module/sweeper/interactor/on_click.mcfunction index 4f9b385..9e3bc45 100644 --- a/data/fzsd/functions/module/sweeper/interactor/on_click.mcfunction +++ b/data/fzsd/functions/module/sweeper/interactor/on_click.mcfunction @@ -6,4 +6,4 @@ execute if score @s fzsd.module.interactor.trigger matches 3600 run tag @s add f execute if score @s fzsd.module.interactor.trigger matches 3601 run tag @s remove fzsd.ignore_sweeper_message execute if score @s fzsd.module.interactor.trigger matches -3300 run function #fzsd:module/sweeper/sweep execute if score @s fzsd.module.interactor.trigger matches -3000 run function #fzsd:module/sweeper/stop_loop -execute if score @s fzsd.module.interactor.trigger matches -3240..-3010 run function #fzsd:module/sweeper/start_loop \ No newline at end of file +execute if score @s fzsd.module.interactor.trigger matches -4900..-4010 run function #fzsd:module/sweeper/start_loop \ No newline at end of file diff --git a/data/fzsd/functions/module/sweeper/post_loop.mcfunction b/data/fzsd/functions/module/sweeper/pre_loop.mcfunction similarity index 96% rename from data/fzsd/functions/module/sweeper/post_loop.mcfunction rename to data/fzsd/functions/module/sweeper/pre_loop.mcfunction index 4bf3b67..d8a4e17 100644 --- a/data/fzsd/functions/module/sweeper/post_loop.mcfunction +++ b/data/fzsd/functions/module/sweeper/pre_loop.mcfunction @@ -1,5 +1,5 @@ # 获取间隔时间 -scoreboard players set fzsd.sweeper.interval_time fzsd.variable.integer 3000 +scoreboard players set fzsd.sweeper.interval_time fzsd.variable.integer 4000 scoreboard players operation fzsd.sweeper.interval_time fzsd.variable.integer += @s fzsd.module.interactor.trigger scoreboard players operation fzsd.sweeper.interval_time fzsd.variable.integer *= -1 fzsd.variable.integer # 设为显示 diff --git a/data/fzsd/functions/module/sweeper/start_timer.mcfunction b/data/fzsd/functions/module/sweeper/start_timer.mcfunction index 4748291..88e0e3b 100644 --- a/data/fzsd/functions/module/sweeper/start_timer.mcfunction +++ b/data/fzsd/functions/module/sweeper/start_timer.mcfunction @@ -4,4 +4,12 @@ execute if score fzsd.sweeper.interval_time fzsd.variable.integer matches 60 run execute if score fzsd.sweeper.interval_time fzsd.variable.integer matches 120 run function fzsd:module/sweeper/timer/2min execute if score fzsd.sweeper.interval_time fzsd.variable.integer matches 180 run function fzsd:module/sweeper/timer/3min execute if score fzsd.sweeper.interval_time fzsd.variable.integer matches 240 run function fzsd:module/sweeper/timer/4min +execute if score fzsd.sweeper.interval_time fzsd.variable.integer matches 300 run function fzsd:module/sweeper/timer/5min +execute if score fzsd.sweeper.interval_time fzsd.variable.integer matches 360 run function fzsd:module/sweeper/timer/6min +execute if score fzsd.sweeper.interval_time fzsd.variable.integer matches 420 run function fzsd:module/sweeper/timer/7min +execute if score fzsd.sweeper.interval_time fzsd.variable.integer matches 480 run function fzsd:module/sweeper/timer/8min +execute if score fzsd.sweeper.interval_time fzsd.variable.integer matches 540 run function fzsd:module/sweeper/timer/9min +execute if score fzsd.sweeper.interval_time fzsd.variable.integer matches 600 run function fzsd:module/sweeper/timer/10min +execute if score fzsd.sweeper.interval_time fzsd.variable.integer matches 720 run function fzsd:module/sweeper/timer/12min +execute if score fzsd.sweeper.interval_time fzsd.variable.integer matches 900 run function fzsd:module/sweeper/timer/15min scoreboard players operation fzsd.sweeper.bossbar.current_time fzsd.variable.integer = fzsd.sweeper.interval_time fzsd.variable.integer \ No newline at end of file diff --git a/data/fzsd/functions/module/sweeper/timer/10min.mcfunction b/data/fzsd/functions/module/sweeper/timer/10min.mcfunction new file mode 100644 index 0000000..c8cf4d0 --- /dev/null +++ b/data/fzsd/functions/module/sweeper/timer/10min.mcfunction @@ -0,0 +1,5 @@ +execute if score fzsd.logger.level fzsd.variable.integer matches ..600 run tellraw @a[tag=!fzsd.ignore_sweeper_message] [{"nbt": "fzsd.level.alert", "interpret": true, "storage": "fzsd:logger"}, {"text": "10分钟后清理掉落物"}] +execute as @a[tag=!fzsd.ignore_sweeper_sound] at @s run playsound minecraft:block.note_block.pling voice @s ~ ~ ~ 1 1 +bossbar set fzsd:sweeper color green +bossbar set fzsd:sweeper value 60 +schedule function fzsd:module/sweeper/timer/5min 300s \ No newline at end of file diff --git a/data/fzsd/functions/module/sweeper/timer/12min.mcfunction b/data/fzsd/functions/module/sweeper/timer/12min.mcfunction new file mode 100644 index 0000000..bb45eb0 --- /dev/null +++ b/data/fzsd/functions/module/sweeper/timer/12min.mcfunction @@ -0,0 +1,5 @@ +execute if score fzsd.logger.level fzsd.variable.integer matches ..600 run tellraw @a[tag=!fzsd.ignore_sweeper_message] [{"nbt": "fzsd.level.alert", "interpret": true, "storage": "fzsd:logger"}, {"text": "12分钟后清理掉落物"}] +execute as @a[tag=!fzsd.ignore_sweeper_sound] at @s run playsound minecraft:block.note_block.pling voice @s ~ ~ ~ 1 1 +bossbar set fzsd:sweeper color green +bossbar set fzsd:sweeper value 60 +schedule function fzsd:module/sweeper/timer/10min 120 \ No newline at end of file diff --git a/data/fzsd/functions/module/sweeper/timer/15min.mcfunction b/data/fzsd/functions/module/sweeper/timer/15min.mcfunction new file mode 100644 index 0000000..6fef3f8 --- /dev/null +++ b/data/fzsd/functions/module/sweeper/timer/15min.mcfunction @@ -0,0 +1,5 @@ +execute if score fzsd.logger.level fzsd.variable.integer matches ..600 run tellraw @a[tag=!fzsd.ignore_sweeper_message] [{"nbt": "fzsd.level.alert", "interpret": true, "storage": "fzsd:logger"}, {"text": "15分钟后清理掉落物"}] +execute as @a[tag=!fzsd.ignore_sweeper_sound] at @s run playsound minecraft:block.note_block.pling voice @s ~ ~ ~ 1 1 +bossbar set fzsd:sweeper color green +bossbar set fzsd:sweeper value 60 +schedule function fzsd:module/sweeper/timer/10min 300s \ No newline at end of file diff --git a/data/fzsd/functions/module/sweeper/timer/5min.mcfunction b/data/fzsd/functions/module/sweeper/timer/5min.mcfunction new file mode 100644 index 0000000..5c59518 --- /dev/null +++ b/data/fzsd/functions/module/sweeper/timer/5min.mcfunction @@ -0,0 +1,5 @@ +execute if score fzsd.logger.level fzsd.variable.integer matches ..600 run tellraw @a[tag=!fzsd.ignore_sweeper_message] [{"nbt": "fzsd.level.alert", "interpret": true, "storage": "fzsd:logger"}, {"text": "5分钟后清理掉落物"}] +execute as @a[tag=!fzsd.ignore_sweeper_sound] at @s run playsound minecraft:block.note_block.pling voice @s ~ ~ ~ 1 1 +bossbar set fzsd:sweeper color green +bossbar set fzsd:sweeper value 60 +schedule function fzsd:module/sweeper/timer/4min 60s \ No newline at end of file diff --git a/data/fzsd/functions/module/sweeper/timer/6min.mcfunction b/data/fzsd/functions/module/sweeper/timer/6min.mcfunction new file mode 100644 index 0000000..d9b402f --- /dev/null +++ b/data/fzsd/functions/module/sweeper/timer/6min.mcfunction @@ -0,0 +1,5 @@ +execute if score fzsd.logger.level fzsd.variable.integer matches ..600 run tellraw @a[tag=!fzsd.ignore_sweeper_message] [{"nbt": "fzsd.level.alert", "interpret": true, "storage": "fzsd:logger"}, {"text": "6分钟后清理掉落物"}] +execute as @a[tag=!fzsd.ignore_sweeper_sound] at @s run playsound minecraft:block.note_block.pling voice @s ~ ~ ~ 1 1 +bossbar set fzsd:sweeper color green +bossbar set fzsd:sweeper value 60 +schedule function fzsd:module/sweeper/timer/4min 120s \ No newline at end of file diff --git a/data/fzsd/functions/module/sweeper/timer/7min.mcfunction b/data/fzsd/functions/module/sweeper/timer/7min.mcfunction new file mode 100644 index 0000000..f54393f --- /dev/null +++ b/data/fzsd/functions/module/sweeper/timer/7min.mcfunction @@ -0,0 +1,5 @@ +execute if score fzsd.logger.level fzsd.variable.integer matches ..600 run tellraw @a[tag=!fzsd.ignore_sweeper_message] [{"nbt": "fzsd.level.alert", "interpret": true, "storage": "fzsd:logger"}, {"text": "7分钟后清理掉落物"}] +execute as @a[tag=!fzsd.ignore_sweeper_sound] at @s run playsound minecraft:block.note_block.pling voice @s ~ ~ ~ 1 1 +bossbar set fzsd:sweeper color green +bossbar set fzsd:sweeper value 60 +schedule function fzsd:module/sweeper/timer/5min 120s \ No newline at end of file diff --git a/data/fzsd/functions/module/sweeper/timer/8min.mcfunction b/data/fzsd/functions/module/sweeper/timer/8min.mcfunction new file mode 100644 index 0000000..7368b6e --- /dev/null +++ b/data/fzsd/functions/module/sweeper/timer/8min.mcfunction @@ -0,0 +1,5 @@ +execute if score fzsd.logger.level fzsd.variable.integer matches ..600 run tellraw @a[tag=!fzsd.ignore_sweeper_message] [{"nbt": "fzsd.level.alert", "interpret": true, "storage": "fzsd:logger"}, {"text": "8分钟后清理掉落物"}] +execute as @a[tag=!fzsd.ignore_sweeper_sound] at @s run playsound minecraft:block.note_block.pling voice @s ~ ~ ~ 1 1 +bossbar set fzsd:sweeper color green +bossbar set fzsd:sweeper value 60 +schedule function fzsd:module/sweeper/timer/5min 180s \ No newline at end of file diff --git a/data/fzsd/functions/module/sweeper/timer/9min.mcfunction b/data/fzsd/functions/module/sweeper/timer/9min.mcfunction new file mode 100644 index 0000000..8fca19c --- /dev/null +++ b/data/fzsd/functions/module/sweeper/timer/9min.mcfunction @@ -0,0 +1,5 @@ +execute if score fzsd.logger.level fzsd.variable.integer matches ..600 run tellraw @a[tag=!fzsd.ignore_sweeper_message] [{"nbt": "fzsd.level.alert", "interpret": true, "storage": "fzsd:logger"}, {"text": "9分钟后清理掉落物"}] +execute as @a[tag=!fzsd.ignore_sweeper_sound] at @s run playsound minecraft:block.note_block.pling voice @s ~ ~ ~ 1 1 +bossbar set fzsd:sweeper color green +bossbar set fzsd:sweeper value 60 +schedule function fzsd:module/sweeper/timer/5min 240s \ No newline at end of file diff --git a/data/fzsd/tags/functions/module/sweeper/start_loop.json b/data/fzsd/tags/functions/module/sweeper/start_loop.json index 2ce888d..1365fc5 100644 --- a/data/fzsd/tags/functions/module/sweeper/start_loop.json +++ b/data/fzsd/tags/functions/module/sweeper/start_loop.json @@ -2,7 +2,7 @@ "replace": false, "values": [ "fzsd:module/sweeper/clear", - "fzsd:module/sweeper/post_loop", + "fzsd:module/sweeper/pre_loop", "fzsd:module/sweeper/start_timer", "fzsd:module/sweeper/bossbar" ]