Tiny Pacman

Level one of Tiny Pacman (Original Version)

Level one of Tiny Pacman (Final Version). Here, the player is temporarily invulnrable after eating a '$' power pill.

Level two of Tiny Pacman (Final Version).

Program listing on 48K Spectrum (original version), with thanks to Einar Saukas for shrinking the listing.

Program listing on 48K Spectrum (final version). Einar Saukas made countless optimisations in order to get this version to exactly fit within the oneliner compo limit.

Text Listing (Final Version)

 POKE 23693,1:
 CLS :
 DIM p(10):
 FOR l=0 TO 4:
 READ w,s,m$,m$:
 FOR t=1 TO 10:
 LET p(t)=85-9*t:
 PRINT AT t,0;m$(t*w-11 TO t*w):
 NEXT t:
 LET m$(p(1)+1)="":
 FOR a=1 TO l+2:
 LET g=p(a):
 LET i=4*RND-2:
 LET i=(a=1)*((k=1)-(k=2)+w*((k=16)-(k=0)))+SGN i*(1+11*(i*i<1))*(g<>p(1)):
 LET c=CODE m$(g+i+1)-45:
 LET p(a)=g+i*(c<2)-i*(m$(g-i+1)<"O")*(c>1)*(a>1):
 PRINT AT g/w+.5,g-w*INT (g/w);m$(g+1);AT w,0;l*58+s;AT p(a)/w+.5,p(a)-w*INT (p(a)/w); INK 7-a*(t<1);"c@@@@@"(a):
 LET t=t-1+(c=-9*a)*(37-t):
 LET s=s+(a=c):
 IF a=1 OR p(a)-p(1) OR t>0 THEN NEXT a:
 POKE (s<56)*23620,w:
 NEXT l:
 DATA 12,1,"OOOOOOOOOOOOO...O......OO.O..OO.OO.OO.OO...$.O.OO....OO....",m$+m$(w TO )+m$

Note on above listing: The game uses the '(c)' copyright character as found in the ZX-Spectrum character set to represent the pacman character. This has been replaced with the standard ASCII 'c' in the above listing.

Download the game (Original version)
Download the game (Intermediate version with better AI)
Download the game (Recommended final version)

About the game (Original Version)

Written for Dr BEEP's One-liner contest 2007, this single line BASIC program listing just fits within the allowed space. (Must not scroll off the screen on a 48K spectrum). The game consists of a 12 by 10 pacman type maze. The player must clear five levels and achieve a score of 290 points in order to complete the game. The first level has one ghost, the second level two ghosts, and so on up to the final level, level five. Due to space limitations of the oneliner contest, the ghosts simply move in a random direction one square at a time, and nothing like true Pacman type ghosts. This makes the later levels quite awkward, as the ghosts can often hover over the few remaining dots.

About the game (Final Version)

Again, Einar Saukas was able to provide invaluable optimisations and ideas to improve the game greatly. Firstly this freed up enough space in the code to allow for two powerpills per level - which make pacman temporarily invulnrable. The other major change was to allow the ghosts two movement attempts per iteration. This made them far more manouverable than in the original version. (There's also an intermediate version put together by Einar, which has better AI than the original instead of powerpills).

Rules of the Game

The Ghosts

@SpeedySpeedy appears as the sole ghost in the very first level. He is the fastest ghost in the game during level 1, but only because the game slows down on the later levels.
@SwampyFirst pops up in level two. Swampy likes to save the environment, and that means killing you reckless eater of dots.
@DandyNow things start to get a little bit tricky. By the time Dandy turns up, there are three ghosts in the maze and they really start to get under your feet.
@KennyBy the time Kenny turns up on level four, the game really starts to slow down. Grabbing the last few dots can now become very tricky, particularly in the dead-end parts of the maze.
@ShadowMaster of stealth, the best kept weapon of "tiny pacman" does not reveal himself until the very last level. Watch out carefully for this ghost, as he is the same colour as the maze, and can catch you unawares.

Hall of Fame
The following people have completed the game
(No-one has yet been known to complete the game)
The following high scores have been submitted
Digital Prawn scored 249 on 20th July 2007

To submit a score to the hall of fame, please send a PM to "Digital Prawn" on the "World of Spectrum" Forums.

Back to Sinclair stuff index