我的 pygame 代码
bif="images.jpg"
mif="point.png"
import pygame, sys
from pygame.locals import *
pygame.init()
screen=pygame.display.set_mode((640,360),0,32)
background=pygame.image.load(bif).convert()
mouse_c=pygame.image.load(mif).convert_alpha()
while True:
for event in pygame.event.get():
if event.type == QUIT:
pygame.quit()
sys.exit()
screen.blit(background, (0,0))
错误信息
Traceback (most recent call last):
File "game.py", line 8, in <module>
background=pygame.image.load(bif).convert()
pygame.error: File is not a Windows BMP file
我试过这个链接,但这也不起作用