[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
Re: [pygame] how to get point where is an image ...
On Tue, 2005-10-11 at 01:17 -0300, Juan Reyes LÃpez wrote:
> player = pygame.image.load('player.jpg').convert()
> .....
> I move player to other point, the initial point was (0,0) how I can
> get new (x,y) where player is drawed?
I'm not sure what is wrong. When you call Surface.blit() it returns a
rectangle that covers where the player was drawn.
player = pygame.image.load('player.jpg').convert()
position = [10, 10]
drawed = screen.blit(player, position)