Skip to main content

Sprite Movement Towards a Target - 1

An example of sprite movement towards a x,y coordinate


Mad Cloud Games
(madcloudgames)
A Documented example of sprite movement towards a x,y coordinate for easy use with programming 2d games. the x,y coordinate is sent with a mouse click. There are lines drawn from one point to the next to show the path of the targets. File includes an example with simple inertia physics and friction and one with basic movement.

Changes

Links

Home Page
http://code.google.com/p/madcloudgames/
Source
http://josh-cockrell.googlecode.com/files/Sprite%20Movement%20Towards%20A%20Target.zip

Releases

Sprite Movement Towards a Target 1 — 13 Jun, 2010

Sprite Movement Towards a Target 1.1 — 3 Sep, 2010

Pygame.org account Comments

  • Nicholas Malacarne 2011-09-14 03:48

    Wow! This is great. Thanks for the source! I'm new to Python and 2D programming in general, and looking over this I can already start to comprehend a little better what I've gotten into. I'll let you know if I end up with something. ;)

  • ZJ.Hubs 2014-01-02 17:25

    In the example without physics, is there any real purpose to having Sprite.speedX and Sprite.speedY? I haven't studied the example with physics included, so maybe I'm missing the point.