20 - Ready for Games/game.js
//STEP 2: defining the game logic

STEP 2: defining the game logic
STEP 2 : defining the game logic
function gameLogic(){
    for (let i in randomObjects){
        if(collide(randomObjects[i], playerBall)){
            randomObjects[i].remove();
            randomObjects.splice(i, 1);
        }
    }
}
function gameLogic ( ) { for ( let i in randomObjects ) { if ( collide ( randomObjects [ i ] , playerBall ) ) { randomObjects [ i ] . remove ( ) ; randomObjects . splice ( i , 1 ) ; } } }
STEP 2: defining the game logic
STEP 2 : defining the game logic
//playerBall.remove();
