master c039d349b334 cached
3 files
2.8 KB
1.0k tokens
5 symbols
1 requests
Download .txt
Repository: sandhikagalih/pukul-tikus-tanah
Branch: master
Commit: c039d349b334
Files: 3
Total size: 2.8 KB

Directory structure:
gitextract_2uxleytg/

├── css/
│   └── style.css
├── index.html
└── js/
    └── script.js

================================================
FILE CONTENTS
================================================

================================================
FILE: css/style.css
================================================
h1, h2 {
  font-size: 60px;
  text-align: center;
  font-family: arial;
  margin: 10px;
}

button {
  display: block;
  margin: auto;
}

.container {
  width: 600px;
  margin: auto;
  cursor: url(../img/palu1.png), auto;
}

.container:active {
  cursor: url(../img/palu2.png), auto;
}

.tanah {
  width: 200px;
  height: 200px;
  position: relative;
  overflow: hidden;
  float: left;
}

.tanah::after {
  content: '';
  display: block;
  width: 200px;
  height: 100px;
  background: url(../img/tanah.png) bottom center no-repeat;
  background-size: 80%;
  position: absolute;
  bottom: -25px;
}

.tikus {
  width: 100%;
  height: 100%;
  background: url(../img/tikus.png) bottom center no-repeat;
  background-size: 60%;
  position: absolute;
  top: 100px;
  transition: top 0.3s;
}

.tanah.muncul .tikus {
  top: -15px;
}

================================================
FILE: index.html
================================================
<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Pukul Tikus Tanah</title>
  <link rel="stylesheet" href="css/style.css">
</head>

<body>
  <h1>Pukul Tikus Tanah</h1>

  <button type="button" class="mulai" onclick="mulai()">Mulai!</button>

  <h2 class="papan-skor">0</h2>

  <div class="container">
    <div class="tanah">
      <div class="tikus"></div>
    </div>
    <div class="tanah">
      <div class="tikus"></div>
    </div>
    <div class="tanah">
      <div class="tikus"></div>
    </div>
    <div class="tanah">
      <div class="tikus"></div>
    </div>
    <div class="tanah">
      <div class="tikus"></div>
    </div>
    <div class="tanah">
      <div class="tikus"></div>
    </div>
  </div>

  <audio src="audio/Pop.mp3" id="pop"></audio>
  <script src="js/script.js"></script>
</body>

</html>

================================================
FILE: js/script.js
================================================
const tanah = document.querySelectorAll('.tanah');
const tikus = document.querySelectorAll('.tikus');
const papanSkor = document.querySelector('.papan-skor');
const pop = document.querySelector('#pop');

let tanahSebelumnya;
let selesai;
let skor;

function randomTanah(tanah) {
  const t = Math.floor(Math.random() * tanah.length);
  const tRandom = tanah[t];
  if (tRandom == tanahSebelumnya) {
    randomTanah(tanah);
  }
  tanahSebelumnya = tRandom;
  return tRandom;
}

function randomWaktu(min, max) {
  return Math.round(Math.random() * (max - min) + min);
}

function munculkanTikus() {
  const tRandom = randomTanah(tanah);
  const wRandom = randomWaktu(300, 1000);
  tRandom.classList.add('muncul');

  setTimeout(() => {
    tRandom.classList.remove('muncul');
    if (!selesai) {
      munculkanTikus();
    }
  }, wRandom);
}

function mulai() {
  selesai = false;
  skor = 0;
  papanSkor.textContent = 0;
  munculkanTikus();
  setTimeout(() => {
    selesai = true;
  }, 10000);
}

function pukul() {
  skor++;
  this.parentNode.classList.remove('muncul');
  pop.play();
  papanSkor.textContent = skor;
}

tikus.forEach(t => {
  t.addEventListener('click', pukul);
});
Download .txt
gitextract_2uxleytg/

├── css/
│   └── style.css
├── index.html
└── js/
    └── script.js
Download .txt
SYMBOL INDEX (5 symbols across 1 files)

FILE: js/script.js
  function randomTanah (line 10) | function randomTanah(tanah) {
  function randomWaktu (line 20) | function randomWaktu(min, max) {
  function munculkanTikus (line 24) | function munculkanTikus() {
  function mulai (line 37) | function mulai() {
  function pukul (line 47) | function pukul() {
Condensed preview — 3 files, each showing path, character count, and a content snippet. Download the .json file or copy for the full structured content (3K chars).
[
  {
    "path": "css/style.css",
    "chars": 823,
    "preview": "h1, h2 {\n  font-size: 60px;\n  text-align: center;\n  font-family: arial;\n  margin: 10px;\n}\n\nbutton {\n  display: block;\n  "
  },
  {
    "path": "index.html",
    "chars": 913,
    "preview": "<!DOCTYPE html>\n<html lang=\"en\">\n\n<head>\n  <meta charset=\"UTF-8\">\n  <meta name=\"viewport\" content=\"width=device-width, i"
  },
  {
    "path": "js/script.js",
    "chars": 1182,
    "preview": "const tanah = document.querySelectorAll('.tanah');\nconst tikus = document.querySelectorAll('.tikus');\nconst papanSkor = "
  }
]

About this extraction

This page contains the full source code of the sandhikagalih/pukul-tikus-tanah GitHub repository, extracted and formatted as plain text for AI agents and large language models (LLMs). The extraction includes 3 files (2.8 KB), approximately 1.0k tokens, and a symbol index with 5 extracted functions, classes, methods, constants, and types. Use this with OpenClaw, Claude, ChatGPT, Cursor, Windsurf, or any other AI tool that accepts text input. You can copy the full output to your clipboard or download it as a .txt file.

Extracted by GitExtract — free GitHub repo to text converter for AI. Built by Nikandr Surkov.

Copied to clipboard!