[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [pygame] simple rectangle drawing
etoffi@softhome.net wrote:
> pre-ps: not on the mailing list
>
> hello, everyone!
>
> i am trying to make a simple game that will use either a series of
> rectangles or circles to make up the display.
[...]
try this:
r = pygame.rect.Rect (left, top, w, h)
if obj == None:
self.background.fill ((0,0,0), r)
else:
self.background.fill (obj.color, r)
pygame.display.update ()
HTH,
Niki Spahiev
____________________________________
pygame mailing list
pygame-users@seul.org
http://pygame.seul.org