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

Re: [pygame] my rpg game (so far)



On Wed, 5 Nov 2008 00:28:42 -0800
"Patrick Mullen" <saluk64007@xxxxxxxxx> wrote:

> No need to place him on the map itself, as long as you position the
> player so that he is aligned with the background.  I assume you are
> doing scrolling?  If you are scrolling by moving, the background, blit
> the player this way:
> self.screen.blit(self.playerimgs[self.frame],
> (self.x+backgroundx,self.y+backgroundy))

Thanks, I got it. However, by having the map drawn to the screen before
the player, the player is always on top of tiles even when it should be
behind it. Therefor I still need some kind of foreground layer. I'm not
sure what the best way to do this is? A subsurface, copy, new surface
with same dimensions? also how am i going to link both layers together
and have the player draw in between? Any help is appreciated.