Commit 0a18c99c by BellCodeEditor

save project

parent 6769ed72
Showing with 3 additions and 11 deletions
...@@ -26,16 +26,6 @@ while True: ...@@ -26,16 +26,6 @@ while True:
exit() exit()
# 按键,控制声音大小 # 按键,控制声音大小
if event.type == locals.KEYDOWN: if event.type == locals.KEYDOWN:
if event.button ==1:
x,y==event.pos
if x<370 and x>270 and y<450 and y>350:
click+=1
if click%2==0:
play_button=stop_img
pygame.mixer.music.unpause
else:
play_button=play_img
pygame.mixer.music.pause
if event.key == locals.K_UP: if event.key == locals.K_UP:
volume += 0.1 volume += 0.1
if volume > 1: if volume > 1:
...@@ -50,7 +40,9 @@ while True: ...@@ -50,7 +40,9 @@ while True:
# 按下鼠标 # 按下鼠标
if event.type == locals.MOUSEBUTTONDOWN: if event.type == locals.MOUSEBUTTONDOWN:
# 次数增加 if event.button ==1:
x,y = event.pos
if x<370 and x>270 and y<450 and y>350:
click += 1 click += 1
if click % 2 == 0: if click % 2 == 0:
play_button = stop_img play_button = stop_img
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment