在这里能找到pygame的下载包 http://www.pygame.org/news.html
要使用,只要 import pygame 即可。
pygame中的操作核心,与J2ME一样,都是sprite(精灵)。
========================================
中间打个岔,因为pygame中经常需要各种角色图片,网上找的又常大小不合适,于是python之
#需要安装PIL包 ( http://www.pythonware.com/products/pil/ )
from PIL import Image
infile = "in.jpg" #输入图片名
outfile = "out.jpg" #输出图片名
im = Image.open(infile)
(x,y) = im.size
x_s = 50 #要生成的图片宽度
y_s = y * x_s/ x #同比例的图片长度
out = im.resize((x_s,y_s),Image.ANTIALIAS)
out.save(outfile)
==================================打岔结束