VSPAN commited on
Commit
678f477
·
verified ·
1 Parent(s): 6a71443

Update index.html

Browse files
Files changed (1) hide show
  1. index.html +7 -1
index.html CHANGED
@@ -499,6 +499,11 @@
499
  window.addEventListener('load', init)
500
  </script>
501
  <script>
 
 
 
 
 
502
  // Функция для "установки" игры с улучшениями
503
  function installGame(gameId) {
504
  try {
@@ -524,6 +529,7 @@
524
  requestAnimationFrame(updateProgress);
525
  } else {
526
  installButton.textContent = 'Играть';
 
527
  message.textContent = 'Игра успешно установлена!';
528
  installButton.disabled = false;
529
  }
@@ -545,7 +551,7 @@
545
  <img src="${game.image}" class="game-image">
546
  <div style="padding: 15px">
547
  <h3>${game.title}</h3>
548
- <button class="steam-button install-button" data-game-id="${game.id}" onclick="installGame(${game.id})">
549
  ${game.installed ? 'Играть' : 'Установить'}
550
  </button>
551
  <div class="install-progress" data-game-id="${game.id}">
 
499
  window.addEventListener('load', init)
500
  </script>
501
  <script>
502
+ // Функция для "игры" — открывает видео
503
+ function playGame(gameId) {
504
+ window.location.href = 'https://www.youtube.com/watch?v=dQw4w9WgXcQ';
505
+ }
506
+
507
  // Функция для "установки" игры с улучшениями
508
  function installGame(gameId) {
509
  try {
 
529
  requestAnimationFrame(updateProgress);
530
  } else {
531
  installButton.textContent = 'Играть';
532
+ installButton.onclick = () => playGame(gameId);
533
  message.textContent = 'Игра успешно установлена!';
534
  installButton.disabled = false;
535
  }
 
551
  <img src="${game.image}" class="game-image">
552
  <div style="padding: 15px">
553
  <h3>${game.title}</h3>
554
+ <button class="steam-button install-button" data-game-id="${game.id}" onclick="${game.installed ? `playGame(${game.id})` : `installGame(${game.id})`}">
555
  ${game.installed ? 'Играть' : 'Установить'}
556
  </button>
557
  <div class="install-progress" data-game-id="${game.id}">