Commit 675efea8 by BellCodeEditor

save project

parent 0dc847f3
Showing with 10 additions and 1 deletions
......@@ -13,7 +13,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') # 中间logo按钮
my_ziti=pygame.font.Font('neuropol.ttf',18)
jiaodu = 0
music_list = []
path = "C:\\Users\\Administrator\\Desktop\\test"
......@@ -84,6 +84,12 @@ while True:
num = 0
pygame.mixer.music.load(path + "\\" + music_list[num])
pygame.mixer.music.play()
play_time = pygame.mixer.music.get_pos()
play_time = int(play_time/1000)
play_m = play_time//60
play_s = play_time%60
info = str(play_m) +":" + str(play_s)
#text = my_ziti.render(info,True,(50,50,150))
if play_button == play_img:
jiaodu = 0
else:
......@@ -97,6 +103,9 @@ while True:
screen.blit(new_logo, (new_rect)) # 中间logo图
screen.blit(last_img, (120, 350)) # 上一曲
screen.blit(next_img, (420, 350)) # 下一曲
#scoreSurf = basic_font.render(info,True,(255,255,255))
text = my_ziti.render(info,True,(50,50,150))
screen.blit(text,(60,430))
# 刷新画面
pygame.display.update()
FPSCLOCK.tick(60)
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