Skip to main content

On Sale: GamesAssetsToolsTabletopComics
Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines
A jam submission

Planetary DefenseView game page

Defende the planed from falling stars! #tweettweetjam 9
Submitted by Elfamir — 1 day, 19 hours before the deadline
Add to collection

Play game

Planetary Defense's itch.io page

How many characters of code did you use?
492

Include your code here, if you'd like to show it off!
x=40y=40e={}b={}ed=0v=0s=0♥=3g=64f=128o=circfill d=del
::_::
h=t()/3m=sin(h)x=g+m*20y=115+-cos(h*2)*10ed-=1v-=1if(ed<1)ed=90add(e,{x=rnd(60)+30,y=-5})
cls(15)o(x,y,2,1)o(g,f,8)line(g,f,x,y)if(btn(❎)and v<1)v=15add(b,{k=x-g,u=y-f,x=x,y=y})
for j in all(b)do
j.x+=j.k*.02j.y+=j.u*.02for l in all(e)do if(abs(l.x-j.x)+abs(l.y-j.y)<5)d(e,l)d(b,j)s+=10end
o(j.x,j.y,1,3)end
for l in all(e)do l.x+=m*.2l.y+=.5?"★",l.x-3,l.y-2,2
if(l.y>f)s-=5♥-=1d(e,l)end
?"♥"..♥.." s:"..s,5,3,1
flip()if(♥>0)goto _

Leave a comment

Log in with itch.io to leave a comment.

Comments

Submitted

I thought it would irritate me at first but the metronome like action of the cannon was strangely entrancing.

Developer

I am glad you liked it! I got fixed on the idea of single-button games for my submissions and this was the best way I could think of making a space invaders like game!

Submitted

Single button games are just the best.