cutechicken commited on
Commit
bdd766a
·
verified ·
1 Parent(s): 233174f

Update index.html

Browse files
Files changed (1) hide show
  1. index.html +18 -18
index.html CHANGED
@@ -374,24 +374,24 @@
374
  }
375
  return true;
376
  });
377
- if(enemies.length === 0) { // 들여쓰기 수정
378
- if (!isBossStage) {
379
- if(currentRound < 10) {
380
- nextRoundBtn.style.display = 'block';
381
- showShop();
382
- } else {
383
- document.getElementById('bossButton').style.display = 'block';
384
- }
385
- } else {
386
- gameOver = true;
387
- document.getElementById('winMessage').style.display = 'block';
388
- restartBtn.style.display = 'block';
389
- bgm.pause();
390
- }
391
- }
392
- }
393
- }
394
-
395
  function spawnHealthItem(x, y) {
396
  items.push({x, y});
397
  }
 
374
  }
375
  return true;
376
  });
377
+ if(enemies.length === 0) {
378
+ if (!isBossStage) {
379
+ if(currentRound < 10) {
380
+ nextRoundBtn.style.display = 'block';
381
+ showShop();
382
+ } else {
383
+ document.getElementById('bossButton').style.display = 'block';
384
+ }
385
+ } else {
386
+ gameOver = true;
387
+ document.getElementById('winMessage').style.display = 'block';
388
+ restartBtn.style.display = 'block';
389
+ bgm.pause();
390
+ }
391
+ }
392
+ }
393
+ enemies.forEach(enemy => enemy.update());
394
+ }
395
  function spawnHealthItem(x, y) {
396
  items.push({x, y});
397
  }