Pygame mouse cursor load/unload

Alex Gardner agardner210 at gmail.com
Sun Mar 10 18:25:51 EDT 2013


On Saturday, March 2, 2013 7:56:31 PM UTC-6, Alex Gardner wrote:
> I am in the process of making a pong game in python using the pygame library.  My current problem is that when I move the mouse, it turns off as soon as the mouse stops moving.  The way I am doing this is by making the default cursor invisible and using .png files as replacements for the cursor.  Perhaps my code would best explain my problem.  I will take help in any way that I can.  Here are the links that contain my code:
> 
> 
> 
> Main class:  http://pastebin.com/HSQzX6h2
> 
> Main file (where the problem lies):  http://pastebin.com/67p97RsJ
> 
> 
> 
> If the links yield nothing, please let me know (agardner210 at gmail.com)

Now the cursor isn't moving at all!

while True:
	for event in pygame.event.get():
		if event.type == QUIT:
			sys.exit()

	screen.blit(bpaddle, paddle_rect)
	# Draw the net
	pygame.draw.line(screen, game.lineColor, game.net1, game.net2, game.netWidth)

	paddle_rect.clamp_ip(bounds_rect)
	screen.blit(beeper, paddle_rect)

	clock.tick(50)

	pygame.display.update()



More information about the Python-list mailing list