Skip to main content

Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines
A jam submission

Knightly LoveView game page

A game about finding love in 558 characters
Submitted by Ryan Kubik (@ryrykubes) — 2 days, 17 hours before the deadline
Add to collection

Play game

Knightly Love's itch.io page

How many characters of code did you use?
558

If you're comfortable with it, paste your game code here, so we can marvel at your achievement!
k='\u265E'
l='\u2665'
n='\u2716'
y='\u25A1'
d=document
c=e=>d.createElement(e)
b=c('p')
d.body.append(b)
s=b.style
s.display='grid'
s['grid-template-columns']='20px '.repeat(8)
h='innerHTML'
r=b.children
for(i=0;i<64;i++){t=c('i')
t[h]=y
b.append(t)}
z=c('p')
b.append(z)
p=23
m=a=>{v=Math.random()*64|0
return v!=a?v:m(a)}
r[m(p)][h]=n
r[m(p)][h]=l
r[p][h]=k
d.addEventListener('keydown',e=>{
q=e.key
x=q=='a'?p-1:q=='d'?p+1:q=='w'?p-8:q=='s'?p+8:p
r[p][h]=y
if(r[x][h]==l){z[h]+=l
r[m(x)][h]=n
r[m(x)][h]=l}
if(r[x][h]==n)z[h]=z[h].slice(3)
p=x
r[x][h]=k})

Leave a comment

Log in with itch.io to leave a comment.

Comments

No one has posted a comment yet