Commit 9711b00e by BellCodeEditor

save project

parent 15c90f3e
Showing with 7 additions and 1 deletions
......@@ -12,7 +12,7 @@ stop_img = pygame.image.load('stop.png') # 暂停按钮
last_img = pygame.image.load('last.png') # 上一曲按钮
next_img = pygame.image.load('next.png') # 下一曲按钮
logo_img = pygame.image.load('logo.png') # 下一曲按钮
myfont=pygame.font.Font("neuropol.ttf",20)
music_list = ["歌曲1.wav","歌曲2.wav","歌曲3.wav","歌曲4.ogg",]
num = -1
......@@ -87,6 +87,9 @@ while True:
pos = (newRect[0],newRect[1])
if play_button == stop_img:
angle += 1
time=pygame.mixer.music.get_pos()
mtime=time//1000//60
stime=time//1000%60
# 绘制画面
screen.blit(bg_img, (0, 0)) # 填充背景
......@@ -94,5 +97,7 @@ while True:
screen.blit(new_logo, pos) # 中间logo图
screen.blit(last_img, (120, 350)) # 上一曲
screen.blit(next_img, (420, 350)) # 下一曲
score=myfont.render(str(mtime)+":"+str(stime),True,(0,0,0))
screen.blit(score,(120,300))
# 刷新画面
pygame.display.update()
\ No newline at end of file
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