From 82adaca14cdf824f98713cd0639f3c86afc0cf87 Mon Sep 17 00:00:00 2001 From: Florian Schmid Date: Thu, 13 Apr 2023 12:40:01 +0200 Subject: [PATCH] fix import bug --- game.js | 2 +- gst.js | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/game.js b/game.js index bc1afea..bcaee6c 100644 --- a/game.js +++ b/game.js @@ -76,7 +76,7 @@ function updateLayout() { document.getElementById("col2").style.backgroundColor = ""; } -export function delay(time) { +function delay(time) { return new Promise(resolve => setTimeout(resolve, time)); } diff --git a/gst.js b/gst.js index 04e96da..ba87634 100644 --- a/gst.js +++ b/gst.js @@ -34,7 +34,9 @@ function getRandomCpu() { } } -import { delay } from "./game"; +function delay(time) { + return new Promise(resolve => setTimeout(resolve, time)); +} export async function btnClick(typ) { // 0 -> Desktop