Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Blakeasd

macrumors 6502a
Original poster
Dec 29, 2009
643
0
Hello,
I would like to create a clone of pac-man for fun. I have my graphics drawn, and I can move the characters. How does AI work? Does anyone know of some Objc AI tutorials?
Thanks
 
How does AI work?

AI? I think it would be a stretch to call what Pac Man was originally built around game mechanics. :p.

Here's a description of how the ghosts move in the original. http://gameinternals.com/post/2072558330/understanding-pac-man-ghost-behavior

Also, the source code to the browser based version Google used as a doodle recently is available. I'm sure you could peruse that for some ideas. http://www.peptop.com/web/google-doodle-pac-man-source-code/

B
 
Others already pointed you to the links about the ghosts, however you may need to implement some kind of path finding algorithm in order for your ghosts to make an educated guess on which path to take. (I could be wrong, I've never thought long and hard about how to make Pacman).

Here is a book that is very good for getting your feet wet with AI. Its written in C++ but that doesn't matter since the same concepts will apply:

http://www.amazon.com/Programming-Game-Example-Mat-Buckland/dp/1556220782
 
As an Amazon Associate, MacRumors earns a commission from qualifying purchases made through links in this post.
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.