public static AxDrawModelMatchList CreateModelSingle(ref AxDrawModelInfo retDrawInfo) { retDrawInfo.RemoveAll(); // 1.弹出对话框设置参数 DialogResult drResult; AxDrawModelEditForm fmModelEditForm = new AxDrawModelEditForm(); fmModelEditForm.ShowDialog(); drResult = fmModelEditForm.DialogResult; if (drResult != DialogResult.OK) { retDrawInfo.RemoveAll(); retDrawInfo.m_eType = EDrawModelType.emTypeNone; AxDrawModelMatchList modelModel = new AxDrawModelMatchList(); return(modelModel); } // 2.根据设置的参数,开始创建 retDrawInfo = fmModelEditForm.GetDrawInfo(); AxDrawModelMatchList drawModel = _CreateModelSingle(retDrawInfo); drawModel.CreateMatchNum(); return(drawModel); }
public List <AxDrawModelPlayerFrom> m_aryPlayerFrom; //此模型队员来源信息 public AxDrawModelModelExport() { m_aryPlayerFrom = new List <AxDrawModelPlayerFrom>(); m_nTempModelID = 0; m_drawInfo = new AxDrawModelInfo(); m_matchList = new AxDrawModelMatchList(); }
//利用DrawInfo信息,创建一个结构 protected static AxDrawModelMatchList _CreateModelSingle(AxDrawModelInfo DrawInfo) { AxDrawModelMatchList retModel = new AxDrawModelMatchList(); if (DrawInfo.m_eType == EDrawModelType.emTypeManual) { return(retModel); } else if (DrawInfo.m_eType == EDrawModelType.emTypeRoundRobin) { AxModelRoundRobin roundRobin = new AxModelRoundRobin(); if (!roundRobin.Create(DrawInfo.m_nSize, DrawInfo.m_bBogol)) { retModel.RemoveAll(); return(retModel); } if (!roundRobin.GetModelExport(retModel)) { retModel.RemoveAll(); return(retModel); } return(retModel); } else if (DrawInfo.m_eType == EDrawModelType.emTypeKonckOut) { AxModelKnockOut knockOut = new AxModelKnockOut(); if (!knockOut.Create(DrawInfo.m_nSize, DrawInfo.m_nRank, false)) { retModel.RemoveAll(); return(retModel); } if (!knockOut.GetModelExport(retModel)) { retModel.RemoveAll(); return(retModel); } return(retModel); } else { return(retModel); } }
public void SetDrawInfo(AxDrawModelInfo drawInfo) { m_stDrawInfo = drawInfo; m_stDrawInfoOld = drawInfo; m_bIsModify = true; //为修改模式 }