GarGerry commited on
Commit
b766c77
·
verified ·
1 Parent(s): 32cc56c

Update index.html

Browse files
Files changed (1) hide show
  1. index.html +3 -2
index.html CHANGED
@@ -41,7 +41,7 @@
41
  let ballPosition = { top: 0, left: Math.random() * 90 }; // Bola muncul secara acak.
42
  let isCaught = false; // Apakah bola ditangkap.
43
  let score = 0; // Skor awal.
44
- let fallSpeed = 0.5; // Kecepatan bola turun lebih lambat.
45
 
46
  // Fungsi untuk memindahkan platform ke kiri
47
  function movePlatformLeft() {
@@ -118,7 +118,8 @@
118
  ball.style.top = ballPosition.top + '%';
119
  platform.style.left = platformPosition + '%';
120
  isCaught = false;
121
- fallSpeed = 0.5; // Reset kecepatan bola
 
122
  }
123
 
124
  // Fungsi untuk menampilkan overlay Game Over
 
41
  let ballPosition = { top: 0, left: Math.random() * 90 }; // Bola muncul secara acak.
42
  let isCaught = false; // Apakah bola ditangkap.
43
  let score = 0; // Skor awal.
44
+ let fallSpeed = 0.5; // Kecepatan bola yang konsisten.
45
 
46
  // Fungsi untuk memindahkan platform ke kiri
47
  function movePlatformLeft() {
 
118
  ball.style.top = ballPosition.top + '%';
119
  platform.style.left = platformPosition + '%';
120
  isCaught = false;
121
+ // Kecepatan bola tidak berubah
122
+ fallSpeed = 0.5; // Tetap sama
123
  }
124
 
125
  // Fungsi untuk menampilkan overlay Game Over