public void SendChat(string s) { if (s == "") { return; } string[] ss = s.Split(new char[] { ' ' }); if (s.StartsWith("/")) { string cmd = ss[0].Substring(1); string arguments; if (s.IndexOf(" ") == -1) { arguments = ""; } else { arguments = s.Substring(s.IndexOf(" ")); } arguments = arguments.Trim(); if (cmd == "generate") { DoGenerate(arguments, false); Gui.DrawMap(); } } Gui.AddChatline(s); }
private void playerMessage(string p) { Gui.AddChatline(p); }