Commit c149dc94 by BellCodeEditor

save project

parent ca2bd065
Showing with 7 additions and 1 deletions
......@@ -10,7 +10,9 @@ next = pygame.image.load('next.png')
stop = pygame.image.load('stop.png')
play = pygame.image.load('play.png')
font = pygame.font.Font('neuropol.ttf',20)
pygame.mixer.music.load('test.wav')
music_list = ['歌曲1.wav','歌曲2.wav','歌曲3.wav','歌曲4.ogg']
num = -1
# pygame.mixer.music.load('test.wav')
fps = pygame.time.Clock()
volume = 0.5
click = 0
......@@ -44,6 +46,10 @@ while True:
pygame.mixer.music.set_volume(volume)
if pygame.mixer.music.get_busy() == False:
sum += 1
if sum > len(music_list)-1:
sum = 0
pygame.mixer.music.load(music_list[sum])
pygame.mixer.music.play()
screen.blit(background,(0,0))
......
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