src/model/map/Lighting.java
public static void computeLighting(World w) {
        for (int y = 0; y < w.yDimension; y++) {
            for (int x = 0; x < w.xDimension; x++) {
                // compute the light value around each lamp based on the range
                if (w.grid[x][y].type == CellType.LAMP) {
                    computeLamp(w, x, y);
                }
            }
        }
    }
/**
     * Each cell has a light value which is calculated based on its proximity to
     * lamps.
     * 
     * The light from lamps attenuates with the square of the distance? Maybe in
     * real, but here it can be customised.
     * 
     */
Each cell has a light value which is calculated based on its proximity to
lamps.

The light from lamps attenuates with the square of the distance. Maybe in
real, but here it can be customised.
Each cell has a light value which is calculated based on its proximity to lamps . The light from lamps attenuates with the square of the distance . Maybe in real but here it can be customised .
public static void computeLighting(World w) {
        for (int y = 0; y < w.yDimension; y++) {
            for (int x = 0; x < w.xDimension; x++) {
                if (w.grid[x][y].type == CellType.LAMP) {
                    computeLamp(w, x, y);
                }
            }
        }
    }
public static void computeLighting ( World w ) { for ( int y = 0 ; y < w . yDimension ; y ++ ) { for ( int x = 0 ; x < w . xDimension ; x ++ ) { if ( w . grid [ x ] [ y ] . type == CellType . LAMP ) { computeLamp ( w , x , y ) ; } } } }
Each cell has a light value which is calculated based on its proximity to
 lamps.
Each cell has a light value which is calculated based on its proximity to lamps .
// compute the light value around each lamp based on the range