public static void ReadStrings(ANode node, ref string[] variable) { if (node == null) { Debug.LogError("Dev.JSON.ReadStrings: Error at \"" + node.ToJSON() + "\": Null!"); } else if (node is Array) { variable = node.AsArray.Children.Select(x => x.Value).ToArray(); } else if (node is Data) { variable = new[] { node.Value }; } else { Debug.LogError("Dev.JSON.TryReadStrings: Error at \"" + node.ToJSON() + "\": Array or Data expected!"); } }
private void LogError() { Debug.LogError("Dev.JSON: Key \"" + _key + "\" not found in: " + _node.ToJSON()); }