public void checkBrick(){
        Brick brick = (Brick)getOneIntersectingObject(Brick.class);
        if ( brick != null )
        {
            if (getY() > brick.getY() || getY() < brick.getY())
            {
                changeY = -changeY;
                // Fixes multi-kill bug
                setLocation(getX(),getY()+1);
                // 1 in 10 hits will recieve upgrade (enlarge Paddle)
                if (Greenfoot.getRandomNumber(10) == 1)
                {
                    // add powerup to drop
                    paddleUpgrade = new LargePaddle();                    
                    getWorld().addObject ( paddleUpgrade, brick.getX(), brick.getY());       
                    paddleUpgrade.fall();
                }
                // 1 in 10 hits will recieve downgrade (shrink Paddle)
                if (Greenfoot.getRandomNumber(10) == 5)
                {
                    // add powerdown to drop
                    paddleDowngrade = new SmallPaddle();
                    getWorld().addObject ( paddleDowngrade, brick.getX(), brick.getY());       
                    paddleDowngrade.fall();
                }
            }
            else
            {   
                // moves ball in opposite direction after collision
                changeX = -changeX;
            }
            // changes brick appearance accordingly
            brick.effect();
            // sound effect
            Greenfoot.playSound("laser.wav");
        }
    }