findCell(x, y) {
        let colIndex = Math.floor((x - matX) / cellDims);
        let rowIndex = Math.floor((y - matY) / cellDims);

        // if out of bounds of grid, return null
        if (colIndex < 0 || colIndex >= this.cols || rowIndex < 0 || rowIndex >= this.rows) { return null; }

        // if there are valid indices, return the row and column
        return { "row": rowIndex, "col": colIndex};
    }
/*
     * Name: findCell
     * Description: Returns cell information at a given pixel
     * Return: An object with cell coordinates
    */
findCell
Description: Returns cell information at a given pixel
Return: An object with cell coordinates
findCell Description : Returns cell information at a given pixel Return : An object with cell coordinates
findCell(x, y) {
        let colIndex = Math.floor((x - matX) / cellDims);
        let rowIndex = Math.floor((y - matY) / cellDims);
        if (colIndex < 0 || colIndex >= this.cols || rowIndex < 0 || rowIndex >= this.rows) { return null; }
        return { "row": rowIndex, "col": colIndex};
    }
findCell ( x , y ) { let colIndex = Math . floor ( ( x - matX ) / cellDims ) ; let rowIndex = Math . floor ( ( y - matY ) / cellDims ) ; if ( colIndex < 0 || colIndex >= this . cols || rowIndex < 0 || rowIndex >= this . rows ) { return null ; } return { "row" : rowIndex , "col" : colIndex } ; }
Name: findCell
 Description: Returns cell information at a given pixel
 Return: An object with cell coordinates
Name : findCell Description : Returns cell information at a given pixel Return : An object with cell coordinates
// if out of bounds of grid, return null // if there are valid indices, return the row and column