汤锅加水音效,烧烤碰撞箱调整
This commit is contained in:
1 parent
c0dd6d8dbe
commit
bf6b18c7a4
13 files changed
+115
-104
No files matched your search
+11
-1
@@ -36,11 +36,17 @@ from ....BlueFoxTools.ToolsConfig import LevelId
|
||||
blockEntityDataComp = comp.CreateBlockEntityData(LevelId)
|
||||
|
||||
# ---- 只导入汤锅自己的数据库 ----
|
||||
from ..TangguoData import SWITCH_RULES, ITEM_USE_ON_RULES, TIMER_RULES, BOWL, PLATE, POT_EMPTY
|
||||
from ..TangguoData import (
|
||||
SWITCH_RULES, ITEM_USE_ON_RULES, TIMER_RULES, BOWL, PLATE, POT_EMPTY,
|
||||
POT_WATER, WATER_BUCKET,
|
||||
)
|
||||
|
||||
# ---- 统一分发器 ----
|
||||
from ...service.FeatureDispatcher import FeatureDispatcher
|
||||
|
||||
# ---- 全服播放音效(加水: 倒水声 bucket.empty_water) ----
|
||||
from ....ModUtil.ServerUtil import PlaySoundToAllClient
|
||||
|
||||
|
||||
class TangguoService(BlueFoxServerSystem):
|
||||
"""
|
||||
@@ -296,6 +302,10 @@ class TangguoService(BlueFoxServerSystem):
|
||||
if recipe.get("target") and action != "take_out":
|
||||
self.replaceBlock(pos, dim, recipe["target"], playerId)
|
||||
|
||||
# 加水音效: 汤锅(空) + 水桶 -> 汤锅(加水) 时, 全服播放"倒水"声(bucket.empty_water)
|
||||
if recipe.get("item") == WATER_BUCKET and recipe.get("target") == POT_WATER:
|
||||
PlaySoundToAllClient((pos[0], pos[1], pos[2], dim), "bucket.empty_water", 1.0)
|
||||
|
||||
# 额外掉落(倒水掉水桶 / 蔬菜乱炖掉汤锅(空) / 汤面掉木碗)
|
||||
if recipe.get("drop"):
|
||||
self.dropItem(dim, pos, recipe["drop"], playerId=playerId)
|
||||
|
||||
Reference in new issue
Block a user