A javascript simple game