diff --git a/assets/js/game.js b/assets/js/game.js index 663205f..8836798 100644 --- a/assets/js/game.js +++ b/assets/js/game.js @@ -41,7 +41,7 @@ function startTimer(){ if(timerRunning) return; timerRunning=true; timerInterval function stopTimer(){ timerRunning=false; clearInterval(timerInterval); } function resetTimer(){ stopTimer(); timerSeconds=0; const dom=document.getElementById('timer'); if(dom) dom.textContent='00:00'; } -/********** HELPERS **********/ +// PEMBANTU FUNGSI function opponentOf(p){ return p===1?2:1; } function inside(r,c){ return Number.isInteger(r) && Number.isInteger(c) && r>=0 && r=0 && c