diff --git a/js/controle.js b/js/controle.js index d1b0161..6a82fe1 100644 --- a/js/controle.js +++ b/js/controle.js @@ -9,6 +9,7 @@ var background background = document.getElementById("background"); +background.loop = true var origemMenu var origemDerrota @@ -196,9 +197,9 @@ function destruirCamadaCreditos() function criarCamadaVitoria() { - var x = document.getElementById("vitoria"); + var audio = document.getElementById("vitoria"); setTimeout(function(){ - x.play(); + audio.play(); }, 200); var fase; @@ -241,9 +242,9 @@ function destruirCamadaVitoria() function criarCamadaDerrota() { - var x = document.getElementById("derrota"); + var audio = document.getElementById("derrota"); setTimeout(function(){ - x.play(); + audio.play(); }, 400); origemDerrota = 1 diff --git a/js/eventosclasses.js b/js/eventosclasses.js index 76459eb..a244df4 100644 --- a/js/eventosclasses.js +++ b/js/eventosclasses.js @@ -52,7 +52,7 @@ document.body.onkeyup = function(e) if(keyunicode >= 65 && keyunicode <= 90) { - keyunicode +=32; + keyunicode +=32; } //Se o codigo estiver dentro do alfabeto diff --git a/js/logica.js b/js/logica.js index eb632c6..c590be1 100644 --- a/js/logica.js +++ b/js/logica.js @@ -32,7 +32,6 @@ function iniciar() jogo.falador.setAttribute("style", "display: none;"); $("#camadaJogo").append(jogo.falador); - jogo.dicaNaTela = document.createElement("div"); jogo.dicaNaTela.setAttribute("id", "dicaNaTela"); jogo.dicaNaTela.setAttribute("tabIndex", "1"); @@ -53,7 +52,6 @@ function iniciar() jogo.contribuicaoNaTela.setAttribute("class", "customfont"); jogo.contribuicaoNaTela.innerHTML = "ContribuiĆ§Ć£o de: "+jogo.bd[jogo.bdAux[jogo.sorteio]].contribuicao; $("#camadaJogo").append(jogo.contribuicaoNaTela); - } $("#camadaJogo").append(jogo.dicaNaTela); @@ -63,7 +61,6 @@ function iniciar() //Pegamos uma palavra aleatoria - jogo.palavraSorteada = jogo.bd[jogo.bdAux[jogo.sorteio]].palavra; jogo.aux = ""; @@ -119,8 +116,6 @@ function update() jogo.pontosParciais = aux; jogo.pontos = jogo.pontos + aux; - - $('