[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
Re: [pygame] road to 1.6
the documentation issues have all been addressed. you check the sprite
reference, and the new 'built in' Tom Chance tutorial.
http://pygame.org/docs/ref/pygame_sprite.html
http://pygame.org/docs/tut/tom/MakeGames.html
i've also added a 'pygame.color' module to handle simple color lookups
and modification.
http://pygame.org/docs/ref/pygame_color.html
the "Color" function may one day become and actual type constructor, but
for now all colors deal with the RGB tuples that pygame uses. the color
module is also added to the "locals" module and the Color function is
added to the toplevel pygame namespace.
>>> import pygame
>>> from pygame.locals import *
>>> color.add(Color('red'), Color('blue')) == Color('0xff00ff')
1
>>> color.multiply(Color('Hot Pink'), (0, 128, 255))
(0, 52, 180, 255)
>>> pygame.color.subtract(200, pygame.Color('0xdeadbeef'))
(0, 27, 10, 16)
http://pygame.org/docs/ref/pygame_color.html
all that's left is a clean implementation to lookup system fonts. if
anyone has any other ideas for the 'color' module i'm up for
suggestions. (it's python code, so additions should not be tough)
http://cvs.seul.org/cgi-bin/cvsweb-1.80.cgi/games/pygame/lib/color.py?rev=1.3