Skip to content

codegolf/ping

Repository files navigation

PING - A Game in < 256 Bytes of HTML+JS

A super minimalistic mix of the classic Pong and Breakout games (without the bricks) in < 256 bytes of HTML and JS. Golfed by @aemkei and .

Demo

PLAY THE DEMO!

Use your keyboard to control the paddle movement.

Source (230 bytes)

<body onload=k=13,x=W=27,X=
Y=1,setInterval('for(i=h=""
,k=k<0?0:24<k?24:k,X=x%W?X:
-X,Y=x<0?1:297<x?(Q=x-299-k
)*Q<4?-1:p:Y,x+=Y*(W+X*Y);i
++<297+k;p.innerHTML=h+888)
h+=i%W?i^x?" ":0:"|\\n"',99
) onkeydown=k+=event.which-
38><pre id=p>

See the annotated source for details.

Gameplay Video

Ping

About

A minimalistic game in < 256 bytes of HTML and JS

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published