My attempt at creating a Bejeweled clone using strictly javascript