PAC-MAN MUSEUM

PAC-MAN MUSEUM

(Servono più voti)
Pac-Man - Guide to Mastering the Maze!
Di Night Druid e altri 1 collaboratori
“All the computer games available at the time were of the violent type - war games and space invader types. There were no games that everyone could enjoy, and especially none for women. I wanted to come up with a "comical” game women could enjoy.“

- Toru Iwatani, Pac-Man creator

"I don't have any problem with any of the ghosts. Remember, I'm perfect!"

-- Billy Mitchell, world Pac-Man champion


About Pac-man:

Pac-Man is one of the most iconic video games of all time, and most people (even non-gamers) have at least a passing familiarity with it. The purpose of the game is very simple — the player is placed in a maze filled with food (depicted as pellets or dots) and needs to eat all of it to advance to the next level. This task is made difficult by four ghosts that pursue Pac-Man through the maze. If Pac-Man makes contact with any of the ghosts, the player loses a life and the positions of Pac-Man and the ghosts are reset back to their starting locations, though any dots that were eaten remain so. Other than simply avoiding them, Pac-Man’s only defense against the ghosts are the four larger "energizer” pellets located at the corners of the maze.

While this sounds relatively simple in concept, getting past the first three mazes can be harder than expected.
This guide is designed to assist players who play the Pac-Man Museum version while also giving information relevant to the original Arcade and MAME incarnations.

The guide will cover how the ghosts work, their motives and most importantly, crucial data on how the ghost AI moves and functions.
   
Premio
Aggiungi ai preferiti
Preferito
Rimuovi dai preferiti
Gameplay Explanation!

Upon inserting quarters / hitting start, the player is placed in a maze filled with food depicted using glowing pellets and dots.
To advance to the next level or stage, Pac-Man needs to eat all of the dots on screen including the power-ups in each corner of the maze.

The task of clearing out the maze of food is made difficult by four mischevious ghosts that pursue Pac-Man through the maze.
If Pac-Man makes contact with any of the ghosts, the player loses a life and the positions of Pac-Man and the four ghosts are reset back to their original starting locations. Despite the player and the ghosts reseting at the start of a new round / life, any dots that were eaten in the previous round do not respawn.

Other than avoiding Blinky, Pinky, Inky and Clyde, Pac-Man does have a way of defending himself against the ghosts. Located in each corner of the maze are four larger "energizer” pellets which will temporarily give Pac-Man a way to fight back!

Eating an "energizer" power-up causes the ghosts to become frightened and flee from Pac-Man's current location for a short time. In the early levels of the game, Pac-Man can use the power-up's ability to eat the ghosts for bonus points. The only down side to this tactic on the higher levels is that the power-ups effectiveness is shortened with every maze completed.

When eaten, a ghost is not completely eliminated, after 3-5 seconds the ghost is returned to its starting position before resuming its pursuit of Pac-Man.

Other than eating dots and ghosts, the only other source of receiving points are the pieces of fruit which appear during each round / level near the middle of the maze.
The first fruit appears when Pac-Man has eaten at least 70 of the dots in the maze, and the second when at least 170 + have been eaten.
Level / Maze Design!

Every level / stage of Pac-Man uses the same maze layout, containing 240 regular “food” dots and 4 energizers. The tunnels that lead off the left and right edges of the screen act as shortcuts to the opposite side of the screen.

The shortcut on the sides of the maze are usable for both Pac-Man and the four ghosts, though the ghosts’ speed is greatly reduced while they are in the tunnel.

Even though the maze layout is always identical to the previous mazes, the levels become increasingly difficult due to modifications to Pac-Man’s speed and changes to both the speed and behavior of the ghosts.

It is worth noting that after reaching level / maze #21, no further changes to the game’s mechanics are made, and every level from 21 onwards is effectively identical.
Maze Tiles / Sprites!
Much of Pac-Man’s design and mechanics revolve around the idea of the board being split into sections or tiles. A “Tile” refers to an 8 x 8 pixel square on the screen.

Because Pac-Man's original arcade resolution is 224 x 288 (3:4), the game uses a total board size of 28 x 36 tiles.


While most of these are not accessible to Pac-Man or the ghosts, they are used by the ghosts to either target Pac-Man's current position or to navigate throughout the maze.

As an example of the impact of tiles, a ghost is considered to have caught Pac-Man when it occupies the same tile as him. In addition, every pellet in the maze is in the center of its own tile.

Despite the dot sprites fiting in their 8x8 tiles, the sprites for Pac-Man and the ghosts are larger than one tile. Because of this, they are never completely contained in a single tile.

For the game’s purposes, the characters are considered to occupy whichever tile that contains its center point. This is important knowledge when avoiding ghosts, since Pac-Man will only be caught if a ghost manages to move the center point of their sprite into the same tile as Pac-Man’s sprite.
Ghost Introduction!




Each ghost is programmed with an individual “personality”, where each ghost uses a different algorithm to determine his / her method of navigation through the maze.

Understanding how each ghost behaves is extremely important to be able to effectively avoid them. However, the logic that the ghosts share is equally as important.

If you do not wish to go into detail about the many functions, scripted events, targeting or various other components that make up the core of the game, you can skip to the ghost profiles.

On the profile for each ghost, a short summary is provided with information that is relevant to that specific ghost.


Tile Targeting!
The key to understanding ghost behavior is the concept of a target tile.

The large majority of the time, each ghost has a specific tile that it is trying to reach, and its behavior revolves around trying to navigate to that tile from its current one.

All of the ghosts use identical methods to travel towards their targets, but the different ghost personalities come about due to the individual way each ghost has of selecting its target tile.

When a ghost selects his / her target tile, there are no restrictions that dictate whether or not a target has to be within the "playable" area.
Because of the lack of restrictions, the ghosts can, and often will attempt to move to a tile located in an inaccessible area, and many of the common ghost behaviors are a direct result of this targeting system.

The end result of the targeting system means that ghosts are almost always motivated by trying to reach a particular tile.
Movement Modes
The ghosts are always in one of three AI modes: Chase, Scatter, or Frightened.

The standard mode is Chase with the ghosts pursuing Pac-Man.
While in Chase mode, all of the ghosts use Pac-Man’s position as a factor in selecting their target tile, however for some ghosts, it is more significant than others.


In Scatter mode, each ghost has a fixed target tile, each of which is located just outside a different corner of the maze. This causes the four ghosts to retreat to the corners whenever they are in this mode.


Frightened mode is the most unique mode, due to the fact that the ghosts do not have a specific target tile.
Instead, they randomly decide which turns to make at every intersection making it difficult to catch them all.


These modes are constantly changing on a timer, while also modifying the timer itself depending on the maze number Pac-Man is currently on.
The timer and schedule is reset at the beginning of each level and / or whenever a life is lost.
The timer is also paused while the ghosts are in Frightened mode.

When Frightened mode ends, the ghosts return to their previously determined mode, while the timer resumes where it left off.

The ghosts start out in Scatter mode at the begining of the round, and there are four waves of Scatter / Chase alterations defined, after which the ghosts will remain in Chase mode indefinitely.

To give an idea of how long a ghost can stay in any given mode, the durations of these phases for the first maze are:

1.Scatter for 7 seconds, then Chase for 20 seconds.
2.Scatter for 7 seconds, then Chase for 20 seconds.
3.Scatter for 5 seconds, then Chase for 20 seconds.
4.Scatter for 5 seconds, then switch to Chase mode permanently.

The durations of these phases are changed when the player reaches level 2, and once again when they reach level 5.

Navigation and decisions!
The AI is very simple and at times, very short-sighted.

This makes the complex behavior of the ghosts even more impressive when you consider that Pac-Man has been around since the early 80's.

The ghosts only ever plan one step into the future as they move about the maze.
Whenever a ghost enters a new tile, it looks ahead to the next tile that it will reach.
By doing so, the ghost makes a decision about which direction it will turn when it gets there.

These decisions have one very important restriction, which is that ghosts may never choose to reverse their direction of travel, even if Pac-Man is directly behind them.

For example, a ghost cannot enter a tile from the right side and then decide to reverse direction and move back to the right. The implication of this restriction is that whenever a ghost enters a tile with only two exits, it will always continue in the same direction.

Any decisions needed for a ghost to navigate the maze are only necessary when approaching “intersection” tiles, which are indicated in green on the maze map.

Another handy technique to be aware of is the use of the four intersections that are colored yellow on the simplified maze map.
These specific intersections have an extra restriction that only applies to the ghosts.
While near the yellow tiles, the ghosts can not choose to turn upwards from these tiles.

If a ghost enters them from the right or left side, they will always proceed out the opposite side via a forced direction-reversal.

This means that if Pac-Man is being pursued by ghosts, he can gain some ground on them by making an upwards turn in one of these intersections, since they will be forced to take a longer route around.


Despite this rule, there is one exception, which is that whenever ghosts change modes, they are forced to reverse direction as soon as they enter the next tile.

This overwrites the decision the ghosts had previously made about the direction to move when they reach that tile.

This effectively acts as a notifier to the player that the ghosts have changed modes, since it is the only time a ghost can possibly reverse directions.
Profile: Red Ghost - Blinky (追いかけ)


The red ghost Blinky, starts outside of the ghost spawn room / house, and is usually the first one to be seen as a threat.

In Japanese, his personality is referred to as 追いかけ, which translates as “pursuer” or “chaser”. Both descriptions are accurate, since Blinky’s target tile in Chase mode is defined as Pac-Man’s current location.


This ensures that Blinky almost always follows directly behind Pac-Man, unless the short-sighted decision-making causes him to take an inefficient path.

Even though Blinky’s targeting method is very simple, he does have one idiosyncrasy that the other ghosts do not.

Blinky's aggressive AI is based on the number of dots remaining, giving him increased speed by 5% while also changing his behavior in Scatter mode to be more like his chase mode.

The change to Scatter targeting is perhaps more significant than the speed increases, since it causes Blinky’s target tile to remain as Pac-Man’s position even while in Scatter mode, instead of his regular fixed tile in the upper-right corner. This effectively keeps Blinky in Chase mode permanently, though he will still be forced to reverse direction as a result of a mode switch.


Blinky is considered to be the most dangerous, as there is no way to indefinitely avoid him during later levels.
Profile: Pink Ghost - Pinky (待ち伏せ)


The pink ghost starts inside the ghost house, but she will always exit immediately after Blinky moves out of the entrance.

Her English nickname is “Pinky”, while her Japanese personality / name is 待ち伏せ, which translates as “ambusher”.

The Japanese name is much more appropriate than her alternate english name of "Speedy", since Pinky moves at the same speed as Blinky and Inky.

Pinky's targeting scheme attempts to move her to the place where Pac-Man is going, instead of where he currently is.
Her target tile in Chase mode is determined by looking at Pac-Man’s current position and orientation, and selecting the location four tiles straight ahead of Pac-Man.

While this was the intended result, it only really works when Pac-Man is facing to the left, down, or right. Unfortunately, when Pac-Man is facing upwards, an overflow error in the game’s code causes Pinky’s target tile to actually be set as four tiles ahead of Pac-Man and four tiles to the left of him.

One important implication of Pinky’s targeting method is that Pac-Man can often win a game of “chicken” with her. Since Pinky's target tile is set four tiles in front of Pac-Man, if Pac-Man heads directly towards her, Pinky’s target tile will actually be behind her.

This will cause Pinky to choose to take any available turn-off in order to loop back around to her target. Because of this, it is a common strategy to momentarily “fake” back towards Pinky if she starts following closely. This will often send her off in an entirely different direction.

Profile: Blue Ghost - Inky (気紛れ)


The blue ghost is nicknamed Inky, and remains inside the ghost house for a short time on the first level, not joining the chase until Pac-Man has managed to consume at least 30-40 percent of the dots.

His Japanese name is 気紛れ, which translates to “whimsical”.
Inky is difficult to predict, because he is the only one of the ghosts that uses a factor other than Pac-Man’s position and orientation when determining his target tile.

During his target selection, Inky uses both Pac-Man’s position and orientation as well as Blinky’s position in his calculation.


To locate Inky’s target, we first start by selecting the position two tiles in front of Pac-Man in his current direction of travel, similar to Pinky’s targeting method. From there, imagine drawing a vector from Blinky’s position to this tile, and then doubling the length of the vector. The tile that this new, extended vector ends on will be Inky’s actual target.

As a result, Inky’s target can vary wildly when Blinky is not near Pac-Man, but if Blinky is in close pursuit, Inky will generally become a more dangerous adversary to elude.

Though Inky is difficult to evade, his “two tiles in front of Pac-Man” calculation suffers from the same overflow error as Pinky’s four-tile equivalent,

If Pac-Man is heading upwards, the endpoint of the initial vector from Blinky (before doubling) will actually be two tiles up and two tiles left of Pac-Man.
Profile: Orange Ghost - Clyde ( お惚け)
The orange ghost, “Clyde”, is the last to leave the ghost house, and does not exit at all in the first level until over a third of the dots have been eaten.

Clyde’s Japanese description is お惚け, which translates to “feigning ignorance”.
The japanese name / personality fits Clyde, since his targeting method can give the impression that he is just “doing his own thing”, without concerning himself with Pac-Man at all.

The unique feature of Clyde’s targeting is that it has two separate modes which he constantly switches back and forth between, based on his proximity to Pac-Man. Whenever Clyde needs to determine his target tile, he first calculates his distance from Pac-Man. If he is farther than eight tiles away, his targeting is identical to Blinky’s, using Pac-Man’s current tile as his target.


However, as soon as his distance to Pac-Man becomes less than eight tiles, Clyde’s target is set to the same tile as his fixed one in Scatter mode, just outside the bottom-left corner of the maze.


The combination of these two methods has the overall effect of Clyde alternating between coming directly towards Pac-Man, and then changing his mind and heading back to his corner whenever he gets too close to Pac-Man.

On the example above, the X marks on the path represent the points where Clyde’s mode switches. If Pac-Man somehow managed to remain stationary in that position, Clyde would indefinitely loop around that T-shaped area.

As long as the player is not in the lower-left corner of the maze, Clyde can be avoided completely by simply ensuring that you do not block his “escape route” back to his corner.
While Pac-Man is within eight tiles of the lower-left corner, Clyde’s path will end up in exactly the same loop as he would eventually maintain in Scatter mode.
Sources

The primary source of all current and older Pac-Man knowledge.
This guide by Jamey Pittman goes beyond the topics that my guide covers, showing off many technical limitations, strategies, patterns, in-depth ghost AI analysis and much more.

My guide condenses some of the information into an easier to understand format while retaining key knowledge needed to proceed through the later levels of Pac-Man's deadly maze.


Please Note:
Most diagrams and images (with the exception of the "Ghost name screen", "the initial start screen", and the individual "Blinky", "Pinky", "Inky" and "Clyde" ghost sprites) are sourced from "The Pac-Man Dossier by Jamey Pittman.
5 commenti
letoffstudios 13 giu 2020, ore 4:34 
This has been an absolutely fascinating read! Thanks for taking the time to make it. :)
xxjumpscarezxx the fox 31 mag 2020, ore 14:57 
good one!
Nax_o 13 feb 2020, ore 6:21 
Good work. The source is of course the best place to look deeper but it's always nice to have guides made for steam in a more tidy format.
GeeTee 29 nov 2019, ore 19:23 
Very interesting to learn the mechanics, now to come up with some strategies!
Mr_Sve 16 ott 2016, ore 13:48 
Well Done :)