mem-fix sedikit logika game
This commit is contained in:
parent
31c073b09c
commit
23d94be273
@ -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<size && c>=0 && c<size; }
|
||||
function belongsTo(v, player){
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user