static public void SetupDialogueOptionsFromJSON(JSONObject json) { int i; for (i = 0; i < json.Count; i++) { int j; JSONObject foo; JSONObject bar; if (json.keys[i] == "Prompts") { foo = json.list[i]; for (j = 0; j < foo.Count; j++) { bar = foo.list[j]; new Dialogue_Prompt(bar.GetField("id").str, bar.GetField("locsuffix").str); } } else if (json.keys[i] == "Options") { foo = json.list[i]; for (j = 0; j < foo.Count; j++) { bar = foo.list[j]; Dialogue_Option newOption = new Dialogue_Option(bar.GetField("id").str, bar.GetField("buttontext").ToString()); } } } Dialogue_Prompt.AddFollowUps(); }