Thanks for playing. I spent hours trying to get it to be like the original Pac-Man AI, but I was unsuccessful. In the end I just went with a simple chase AI to make it playable. I plan on revisiting the code once voting is done.