Commit 90702fe4 by BellCodeEditor

auto save

parent 2a4abfc6
Showing with 1 additions and 2 deletions
...@@ -17,6 +17,7 @@ pygame.mixer.music.load('歌曲1.wav') ...@@ -17,6 +17,7 @@ pygame.mixer.music.load('歌曲1.wav')
pygame.mixer.music.load('歌曲2.wav') pygame.mixer.music.load('歌曲2.wav')
pygame.mixer.music.load('歌曲3.wav') pygame.mixer.music.load('歌曲3.wav')
x,y=0,0
volume = 0.2 volume = 0.2
asdf=[] asdf=[]
pygame.mixer.music.set_volume(volume) # 初始播放音量 pygame.mixer.music.set_volume(volume) # 初始播放音量
...@@ -24,12 +25,10 @@ click = 0 ...@@ -24,12 +25,10 @@ click = 0
play_button = stop_img play_button = stop_img
path=r"C:\Users\Administrator\Desktop\test" path=r"C:\Users\Administrator\Desktop\test"
fil=os.listdir(path) fil=os.listdir(path)
print(fil)
num = -1 num = -1
for i in fil: for i in fil:
if i[-4:]==".wav" or i[-4:] == ".ogg": if i[-4:]==".wav" or i[-4:] == ".ogg":
asdf.append(i) asdf.append(i)
print(asdf)
while True: while True:
for event in pygame.event.get(): for event in pygame.event.get():
......
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