增加帮助菜单打开音效
This commit is contained in:
parent
bf3fdc08b9
commit
6ae7007bb9
BIN
resources/sound/helpScreen.ogg
Executable file
BIN
resources/sound/helpScreen.ogg
Executable file
Binary file not shown.
@ -660,6 +660,7 @@ def _getSound(filename):
|
|||||||
# 所有音效的元组,用一波海象算子表达(>= python 3.8),免得要维护两个
|
# 所有音效的元组,用一波海象算子表达(>= python 3.8),免得要维护两个
|
||||||
SOUNDS = ( # 程序交互等
|
SOUNDS = ( # 程序交互等
|
||||||
SOUND_TAPPING_CARD := _getSound("tap.ogg"),
|
SOUND_TAPPING_CARD := _getSound("tap.ogg"),
|
||||||
|
SOUND_HELP_SCREEN := _getSound("helpScreen.ogg"),
|
||||||
# 植物
|
# 植物
|
||||||
SOUND_FIREPEA_EXPLODE := _getSound("firepea.ogg"),
|
SOUND_FIREPEA_EXPLODE := _getSound("firepea.ogg"),
|
||||||
SOUND_BULLET_EXPLODE := _getSound("bulletExplode.ogg"),
|
SOUND_BULLET_EXPLODE := _getSound("bulletExplode.ogg"),
|
||||||
|
|||||||
@ -223,6 +223,7 @@ class HelpScreen(tool.State):
|
|||||||
self.setupImage()
|
self.setupImage()
|
||||||
pg.display.set_caption("pypvz: 帮助")
|
pg.display.set_caption("pypvz: 帮助")
|
||||||
pg.mixer.music.stop()
|
pg.mixer.music.stop()
|
||||||
|
c.SOUND_HELP_SCREEN.play()
|
||||||
|
|
||||||
def setupImage(self):
|
def setupImage(self):
|
||||||
# 主体
|
# 主体
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user