public boolean checkCollision(Player.Direction direction, int x, int y, int width, int height){
		int xIndex = 0;
		int yIndex = 0;
		
		switch(direction){
		case Up:
			xIndex = x / GRID_SIZE;
			yIndex = (y - height/2) / GRID_SIZE;
			break;
		case Down:
			xIndex = x / GRID_SIZE;
			yIndex = (y + height/2) / GRID_SIZE;
			break;
		case Left:
			xIndex = (x - width/2) / GRID_SIZE;
			yIndex = y / GRID_SIZE;
			break;
		case Right:
			xIndex = (x + width/2) / GRID_SIZE;
			yIndex = y / GRID_SIZE;
			break;
		}
				
		if(grid.get(yIndex).get(xIndex) == GridType.Wall)
			return true;
		
		return false;
	}