public void ToObject(string sentence, PlayerRegister reg) { string[] stage1 = sentence.Split(';'); string[] stage11 = stage1[0].Split(','); this.from_str = stage11[0]; this.to_str = stage11[1]; string[] stage12 = stage1[1].Split(','); for (int i = 0; i < stage12.Length; i++) { this.action.Add(stage12[i].Split(':')); } }
public void ToObject(string sentence, PlayerRegister reg) { string[] stage1 = sentence.Split(';'); string[] stage11 = stage1[0].Split(','); this.from_str =stage11[0]; this.to_str = stage11[1]; string[] stage12 = stage1[1].Split(','); for (int i = 0; i < stage12.Length; i++) { this.action.Add(stage12[i].Split(':')); } }
public Sentence(string sentence, PlayerRegister reg) { this.ToObject(sentence, reg); }