I have written a demonstration of a simple path-finding algorithm (in Python), for use in grid-based computer games. It used a breadth-first search to route a sprite from one part of a map to another, avoiding obstacles in between. The code is a listing taken from my forthcoming book, Beginning Game Development with Python and Pygame. There's no documentation I'm afraid. If you want to know how it works, you will have to buy the book. :-)

Download path finding demo

To run it, you will need PyGame, and of course Python. The code is completely public domain, use it for whatever purpose you want and you don't owe me a penny. Here be a screenshot...

fuguswim
This blog post was posted to It's All Geek to Me on Friday April 20th, 2007 at 6:07PM
 

5 Responses to "Swim Fugu, Swim"

  • Jay P
    April 20th, 2007, 7:17 p.m.

    Amazon is saying August for publishing. Any chance it'll be out earlier?

  • April 20th, 2007, 7:33 p.m.

    Sorry, it's unlikely to be out any earlier!

  • April 21st, 2007, 10:34 p.m.

    Excellent. I can't wait to get a hold of this book, although it will be little new to me, I want something to recommend to my friends and the newcomers to #python @ freenode who are always asking for good books. Good luck!

  • July 11th, 2007, 5:35 a.m.

    Looks like a neat book. I might be able to make my computer science teacher get a copy or two, and we can use them for our after-school programming stuff. I'm not too great on teaching this stuff.

  • July 27th, 2007, 11:29 a.m.

    I cant wait to buy the book! :D

Leave a Comment

You can use bbcode in the comment: e.g. [b]This is bold[/b], [url]http://www.willmcgugan.com[/url], [code python]import this[/code]
Preview Posting...
Previewing comment, please wait a moment...

My Tweets

Will McGugan

My name is Will McGugan. I am an unabashed geek, an author, a hacker and a Python expert – amongst other things!

Search for Posts
Possibly related posts
Tags
Popular Tags
 
Archives
2013
 
Recent Comments
Trying to implement this code. What are the requirements? Does it need a certain version of PHP, etc? Do I ...
No an ad.cssSlider is a free slide show creator with the Kenburns effect (and very few others), it is a ...
No an ad.cssSlider is a free slide show creator with the Kenburns effect (and very few others), it is a ...
Hi Will Can't seem to run any pyopengl applications on my Win7 64bit setup. Using python 3.3 but keep getting ...
Great work, is it possible to jump to a specified picture?
 
© 2008 Will McGugan.

A technoblog blog, design by Will McGugan