4

I want to make a game that will be similar to Pac-Man from scratch. I don't want to use a games engine either, just plain old Xcode.

Basically the game would consist of a map that fits the screen, walls within the map, food, enemies and a player.

I just wanted to know what the best way forward would be. I plan on creating the map first, and then doing everything else after that. Where should I begin?

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
max_
  • 24,076
  • 39
  • 122
  • 211
  • 4
    If you want to actually replicate the AI of the ghosts, there's an awesomely detailed discussion here: http://www.stumbleupon.com/su/2wKX2M/gameinternals.com/post/2072558330/understanding-pac-man-ghost-behavior – Ben Zotto Apr 07 '11 at 21:46

1 Answers1

3

I plan on creating the map first

Keeping in mind that you'll probably want several maps, you might want to create a map editor first, which would let you place "wall" graphics and define the paths along which the player & ghosts are allowed to travel. If you define those paths with nodes at each intersection, the ghost AI becomes easy to solve with A* path finding. Your map editor can use the distance between intersections to calculate the "weight" of each path segment.

Sherm Pendley
  • 13,556
  • 3
  • 45
  • 57
  • thanks, but how could I do this? Are there any examples online on how I could do this? – max_ Apr 07 '11 at 21:44
  • 1
    I'm pretty sure Pac-Man only had one map. Maybe you're thinking of Ms. Pac-Man, the far superior game ;) – Ben Zotto Apr 07 '11 at 21:45
  • @XcodeDev - I'd start with the "Sketch" example that's included with Xcode. It's not a game, but it's a bare-bones drawing app that could form a good foundation on which to build a map editor. – Sherm Pendley Apr 07 '11 at 21:49
  • @quixoto - Right on both counts! Ms. Pac-Man had multiple maps and randomized ghost movement, both of which made for a *much* better game. – Sherm Pendley Apr 07 '11 at 21:50