public static string[] List(string index, string[] content) { string[] result = new string[content.Length + 2]; LuaTableWriter.IndentLines(ref content); result[0] = "[\"" + index + "\"] = {"; content.CopyTo(result, 1); result[content.Length + 1] = "},"; return(result); }
public static string[] Table(string container, string title, string[] content) { string[] result = new string[content.Length + 2 + LuaTableWriter.EmptyLinesBetweenTables]; LuaTableWriter.IndentLines(ref content); result[0] = container + "[\"" + title + "\"] = {"; content.CopyTo(result, 1); result[content.Length + 1] = "}"; return(result); }