public void ApplyInfo(int _row, int _column, int type, int[][] _matrix, Vector2[] pings) { //Disable Player + Enemy Player.DisableAllMember(); Enemy.DisableRender(); //Apply row + column Row = _row; Column = _column; Matrix = new int[Row, Column]; //Apply the matrix for (int i = 0; i < Row; ++i) { for (int j = 0; j < Column; ++j) { Matrix[i, j] = _matrix[i][j]; } } //ObstacleManager.Instance.ClearObstacle(); MapGenerator.Instance.GenerateMap(Row, Column, type, Matrix); //Apply the announce pos for (int i = 0; i < pings.Length; i += 2) { PingCell((int)pings[i].x, (int)pings[i + 1].y); } }