added environment, grid.cc