[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [pygame] Diffefrences between sprite.Group and sprite.RenderUpdates (and Group.draw question)



oops forgot to paste the link. Here it is:
http://www.pygame.org/project/492/

:-)

On Sun, May 4, 2008 at 8:29 AM, PyMike <pymike93@xxxxxxxxx> wrote:
Hey Luca,

RenderUpdates() is just a Group() with a speedy draw function.

If you want to draw stuff in the order of their y positions, Andy Sommerville made a script called "LayeredUpdates", (unfortunately, there's also a object called LayeredUpdates in pygame) which lets you control which layers they're on, and if they're all on the same layer, it will draw stuff according to their y positions.

HTH,


On Sun, May 4, 2008 at 7:38 AM, Luca <lucafbb@xxxxxxxxx> wrote:
Hi all.

Reading pygame docs I found an example using a group that store all
sprites defined as a RenderUpdates, not simple Group.

The pydoc of this class don't give me much infos. Can someone explain
me what is the difference?

I found this because I'm having some problems with a game I'm
developing. The call of

   all.draw

(where "all" is for now a RenderUpdates instance) draw sprites on the
screen in some order. There is a way to control the order of sprites
drawed on screen? I like to blit images ordered on Y position on the
screen.

Any help will be really appreciated!

--
-- luca



--
- pymike (http://pymike.aftermatheffect.com/)



--
- pymike (http://pymike.aftermatheffect.com/)