This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- Dentro do body, mas fora do palco, cria label para exibir o placar --> | |
<label id="placar">Fantasmas capturados: <span>0</span></label> | |
<!-- Associa a função capturar() ao evento onclick da imagem fantasma1 --> | |
<img src="fantasma1.svg" alt="Fantasma número 1" id="fantasma1" onclick="capturar()"> | |
<script> | |
const $placar = document.getElementById('placar'); | |
let fantasmasCapturados = 0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#placar { | |
/* Para que seja possível definir tamanho e margin */ | |
display: block; | |
/* Para que com margin left/right auto fique alinhado a esquerda com o palco */ | |
width: 80%; | |
/* Para "centralizar" horizontalmente */ | |
margin: 0 auto; | |
font-size: 1.5em; | |
padding: .2em; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<label id="cronometro">Tempo: | |
<span>10</span> | |
</label> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const $cronometro = document.getElementById('cronometro'); | |
let tempoSegundos = 10; | |
// Define o intervalo de repetição em milissegundos. | |
let refreshIntervalId = setInterval(jogo, 1000); | |
function atualizaTempo() { | |
tempoSegundos--; | |
$cronometro.innerHTML = `Tempo: <span>${tempoSegundos}</span>`; | |
if (tempoSegundos <= 0) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<style> | |
.display { | |
display: flex; | |
justify-content: space-between; | |
/* Para que com margin left/right auto fique alinhado a esquerda com o palco */ | |
width: 80%; | |
/* Para "centralizar" horizontalmente */ | |
margin: 0 auto; | |
font-size: 1.5em; | |
padding: .2em; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<meta http-equiv="X-UA-Compatible" content="ie=edge"> | |
<title>Caça fantasmas</title> | |
<style> | |
#palco { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
url = "" | |
while url == "": | |
url = input("Informe a URL desejada: ") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
numero_de_paginas = input("Informe a quantidade de páginas: ") | |
if numero_de_paginas == "": | |
numero_de_paginas = 1 | |
else: | |
numero_de_paginas = int(numero_de_paginas) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<meta http-equiv="X-UA-Compatible" content="ie=edge"> | |
<title>Morning Coffee</title> | |
<link rel="stylesheet" href="style.css"> | |
</head> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<body> | |
<!-- O vídeo --> | |
<video autoplay muted loop id="meuVideo"> | |
<source src="morning-coffee.mp4" type="video/mp4"> | |
</video> | |
</body> |