Hacker News new | past | comments | ask | show | jobs | submit login
A game when games were new (medium.com/i-3-video-games)
377 points by tylerneylon on April 1, 2013 | hide | past | favorite | 64 comments



If anyone wants to read how Pac-Man works on a very deep level, check out: http://home.comcast.net/~jpittman2/pacman/pacmandossier.html

It's super interesting.


... and the deep meaning of Pac-Man: http://www.smbc-comics.com/?id=2736


what he said. that link is the original source with absolutely expansive depth into the topic. everyone else seems to be grabbing parts and republishing.


Looks like I'm not getting anything done today.


Cool! Thanks for sharing!


"Along the way, I jumped into the rabbit hole of Pac-Man minutiae and came out impressed with some of the clever firsts the game pulled off.

When Halo came out in 2001, it was praised for its dynamic soundtrack, which was more reactive to players’ actions than many previous games. Ahead of its time, Pac-Man had a crude version of a dynamic soundtrack in 1980."

Close. The Flash pinball machine from Williams Electronics (released January 1979) had a background sound that changed dynamically as game play progressed and is considered the first. Pac-Man came slightly later (May 1980 in Japan, October 1980 in the USA).


When I saw that quote I was instantly reminded of:

"During the Old Stone Age, between thirty-seven thousand and eleven thousand years ago, some of the most remarkable art ever conceived was etched or painted on the walls of caves in southern France and northern Spain. After a visit to Lascaux, in the Dordogne, which was discovered in 1940, Picasso reportedly said to his guide, “They’ve invented everything.

What those first artists invented was a language of signs for which there will never be a Rosetta stone; perspective, a technique that was not rediscovered until the Athenian Golden Age; and a bestiary of such vitality and finesse that, by the flicker of torchlight, the animals seem to surge from the walls, and move across them like figures in a magiclantern show (in that sense, the artists invented animation). They also thought up the grease lamp—a lump of fat, with a plant wick, placed in a hollow stone—to light their workplace; scaffolds to reach high places; the principles of stencilling and Pointillism; powdered colors, brushes, and stumping cloths; and, more to the point of Picasso’s insight, the very concept of an image. A true artist reimagines that concept with every blank canvas—but not from a void"

http://www.newyorker.com/reporting/2008/06/23/080623fa_fact_...

Nothing is new, etc.


Even better, it's recently been found that in many of these ancient sites, the paintings cluster at the points in the cave where the human voice resonates best. Apparently it's possible to walk through the caves in darkness, shouting and clapping, and when one hits a peak of resonance, to turn on ones torch and be suddenly surrounded by art.

http://www.insidescience.org/content/caves-stonehenge-ancien...


The BBC Radio four programme 'Noise, a Human History' had an episode (the first?) exploring this. They had people clapping in caves. It's fascinating.

The BBC don't seem to have this available on any of their catch-up services. (It's probably around on unofficial places.)

(http://www.bbc.co.uk/programmes/b01rglcy)


In fact, they're all available apart (currently) from episode 3 - http://www.bbc.co.uk/programmes/b01rglcy/episodes/guide


I'm sure you have already seen it, but if not check out 'Cave of Forgotten Dreams' - Werner Herzog - it blew me away, the art and artistry is stunning in those caves.


Don't forget Space Invaders (1978). The four note background drone speeds up a little bit with each alien you kill (along with the aliens themselves, of course).


I read recently that the speed of the aliens, and I am guessing the sound, is based on how many are left to draw on the screen. The less aliens, the faster it is to draw, the faster they move.


From memory the code moves one invader one pixel[1] each video frame.

[1] Might be wrong and it's multple pixels.


That value might be correct, but I think what megablast is getting at is that the original hardware wasn't able to calculate the position of all of the invaders and still maintain the video frame rate.

So even though it was intended to work the same speed all the time, the hardware was limited in its ability to handle all of the aliens: once there were less to draw, it was able to draw them faster.

From http://en.wikipedia.org/wiki/Space_invaders#Hardware : While programming the game, Nishikado discovered that the processor was able to render the alien graphics faster the fewer were on screen. Rather than design the game to compensate for the speed increase, he decided to keep it as a challenging gameplay mechanic.


I also thought this was interesting as well...it's incredibly subtle in pacman, but it makes the end of a level much more frantic.

It seems to be a common idea at the time, IIR Asteroids (Nov 1979) did something similar with its two tone Jaws-alike soundtrack.


Yeah, it was kind of the "latest thing" at the time, since the sound effects available from coin-op games were somewhat primitive. There wasn't even speech synthesis or sampled playback yet (that came later in 1979 with Williams' Gorgar pinball and in 1980 with Taito's Stratovox video)


That's fascinating. Congratulations to Tyler for not only sharing this story but also sharing this as a project on GitHub. It's quite a bit of code and a nice peek into the world of Lua game programming for me, since I've had very little contact with this language.


Thank you! Lua is great fun - very similar to javascript. The only weird part for me is that it's 1-indexed, but I see that as a feature for kids learning to program for the first time.

Also, the code for PacPac is not very clean. Just like javascript, globals in Lua are the default, easy to use, and require discipline to avoid :)


You might want to look into strict.lua for avoiding unwanted globals: http://metalua.luaforge.net/src/lib/strict.lua.html

It's a little script that you can add to your Lua project and will check for usage of globals in functions without prior assignation in the global scope. Quite nifty.


I had never really been a fan of PacMan before, but for last month's 1GAM [0] I decided to build a clone. Once I started reading into it, I was pretty fascinated by the amount of depth the game has. As said in the article, pretty amazing for something running on a 3 MHz Z80.

[0] http://www.onegameamonth.com/


By the way, Ernest Cline’s Ready Player One is great fun, and you should read it.


Seconded! Or have Wil Wheaton read the book to you, including his own surprise cameo appearance. It's a fun story and excellently narrated.

http://www.audible.com/pd?asin=B005FRGT44


Well, it would have been a surprise, anyway. (Currently on "page 31" ("location 623 of 7372").

I actually didn't read the article above once I saw the mention of the book to avoid spoilers. Guess I should have boycotted the comments as well....


For anyone interested in PacMan, The PacMan Dossier is a must-read: http://home.comcast.net/~jpittman2/pacman/pacmandossier.html


Seconding this - was going to post it as well. Fun reading.


Namco shut down my Pac-Man project [0] last year on github after it was posted to Hacker News. Good luck :/

In short, it works on mobile devices, uses HTML5 Canvas, has ghost visualizations, and Braid-like rewind.

Read about it and play it here:

[0] http://pacman.shaunew.com/


What grounds did they give for removing the project? Trademark? Copyright?


Infringed on intellectual property rights:

[1] https://github.com/github/dmca/blob/master/2012-09-25-namco....


Highlights the absurdity of 'intellectual property rights' law. Like being sued for playing Bach or Chopin to an audience in terms of the digital era.


Wow, this is awesome. Features I love: practice mode; cookie-man mode (brilliant); and the learning section that visually explains the AI's.


Thanks a lot!


In 1980, four of us - myself and three co-workers, attempted to write a pac-man like game. I really haven't had much interest in game programming, but one guy did and wrote a basic display with keyboard moves. The ghosts were in the form of each of our initials, and the plan was each of us would program our own ghost strategy algorithms. It never got too far along. I should also mention that this was written in Pascal for the Texas Instruments 990 (not the POS 99/4a home computer) business computer on 80x24 monocolor text-only screens. Hey, but it was multitasking and multiuser - each of us could be playing our own copy of the game. My Windows 7 PC still gives regular demonstrations of its non-multitasking DOS heritage. In 1982 I bought an Apple II Plus thinking I might develop some games... coming from a mainframe and minicomputer environment, I was more than a little disappointed. I didn't return to PC programming or even own a PC until 1988 when I found out SCO Xenix would run on a 286... for weeks at a time, with multiple users, without crashing. Gaming has come a long way, but some OS fundamentals still haven't, at least not in the PC world.


This almost reminds me of the time that i wrote a fully customizable pacman game back in '09 , The AI was not state of the art (because i was new to Computer science). But the Level were completely custom , you just had to edit a text file in which you set the collision color [1], and provide two new images ( one for food locations and the other for the map) and you had a new level.

The code was a mess [2] ( i didn't even know about OOP back then )but i keep it for historical purposes ( like it was the first game i ever wrote).

[1] https://github.com/fahadm/Historical/blob/master/PACMAN/Sett...

[2] https://github.com/fahadm/Historical/blob/master/PACMAN/page...


Cool. I recall designing levels for a Pac-Man clone my friends made on the Atari ST back in 1992: https://www.giantbomb.com/crapman/3030-24791/images/?tag=All...

Unfortunately none of the downloadable images seem to be available anymore:

- Synergy Megademo: http://www.pouet.scene.org/prod.php?which=752

- Crapman standalone: http://www.pouet.scene.org/prod.php?which=29339

Fun fact: the musician went on the make music and sound effects for games like Z and Killzone and win an Ivor Novello award: http://www.screenedmusic.com/news/joris-de-man-wins-ivor-nov...


The ghost AI from pacman is a masterpiece in itself


If one of his intentions was to inspire tinkering, then it worked. I tweaked the game to include an extra 6 ghosts and speed up pacman. More fun, but still hard. Had to randomize their leave box time to make them not appear as one.


LÖVE has a Web player (using WebGL and Lua.js) in the works, would be cool to see if Pac-Pac runs on it: https://github.com/ghoulsblade/love-webplayer


Well I just spent a while on it but there are quite a few filesystem functions missing in either Lua.js or love web player to make it work out of the box. It's probably doable but I gave up for now.


Also interesting and related to pacman: patterns to get a rather easy victory http://www.math.montana.edu/~hyde/pacman/ and also the hidden spot in pacman http://www.youtube.com/watch?v=aFGoiQAzG-I


This was an actual challenge at a hack-a-thon I was at way way back (I'm guessing around '92). The total instructions were pretty much "(best game category) build a pac man variant", the restriction to pac man only mostly there to render quite a bit of the prior-to-the-event design less useful when it was announced. It was over 48h though. There were some pretty creative entries. I built one with more ghosts (increasing per level) with generated mazes, but from a predetermined per-level seed so that level 1 was always level 1, but there were still infinite(ish) levels (I was in a kind of Elite phase again after Elite II). Didn't even end up entering, I'd had a HD crash a few days before so I didn't even have my normal go-to bag-o-tricks in terms of stuff to render, time, do controls, etc and did it from scratch. By deadline it worked "almost some" but not enough to really be playable.


I cannot.scroll or.zoom the site on my android :(


what version/browser?


Dolphin Lite

but also happens on default android browser (Android 2.3)

It happens in a lot of sites, I wonder what it is that people do that cause that.


This is the line that does it:

<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1" user-scalable="no">


Is this fixed in later versions of Android?


What's there to fix? The tag says "you cannot zoom this site to levels less than 1.0 or more than 1.0", the browser complies. I'm not proud of it, but I've used this very approach to fix a stupid bug in iOS Safari - rotating the device without this zoom lock changed the zoom in ridiculous ways.


Why should that stop you from scrolling the screen?


That tag can stop you from scrolling sideways because it also says "the width of this document should be the same as the width of the device", killing all horizontal scrolling. It shouldn't affect vertical scroll though, unless height is constrained through some other styling rules.


Aka, the <fuckyou> tag, which is the standard for declaring that the designer cares more about how it looks on their own machine than letting readers consume the content


Some of it may be explained by early editions of the HTML5 Boilerplate "best practices".

See: https://github.com/h5bp/html5-boilerplate/blob/ed906cfb1b429...


Ah, I wonder if that's why I can't scroll with the keyboard in Firefox.


Great post. The only thing I was missing is finding out whether you managed to do it in one day after all (including all the research?)


Essentially yes. Day one had all the ghost AI's and power pellets and lives and death. No sound and no score, though. It was completely made possible by the game engine (Löve) and the excellent Pac-Man analysis by other authors like Chad Birch.

You can see the exact state of the game at day one:

git clone git@github.com:tylerneylon/pacpac.git

git checkout 4abf17ca62dffd2ac3245f6ab06cc28fb9021791

You can return to the latest commit later via:

git checkout master

You can get the game engine (required to play) from http://love2d.org .


Games like these are relatively easy to make with modern game engines like Löve. There are many original indie games in early development worth checking out:

http://love2d.org/forums/viewforum.php?f=5


So what happened to the dare? It seems there are more rabbit holes than would allow one to push out a full PacMan clone in a single day.


This makes me want to read Ready Player One all over again and make a retro game, fun post, thanks!


Oh, one byte is fine for the level. No one will ever come close to reaching anything higher!


Well, two bytes is quite the challenge then, isn't it?


Okay hack-a-thon man, go program this in z80 assembly, and post THAT to git hub.


Did you even read the post, his point was that modern tools and frameworks make it easy today to do what once had to be done at a lower level.


wow! I find this so interesting. What a great opportunity to get into game programming. Now I just need some time to check this out.


Has anyone tried to transfer this AI model to FPS?


Trying to figure out how to scroll was a great game. Page down? Nope. Down arrow? Nope.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: