//分两步初始化 public void Init(MapController m, string _name, int _step, int stepMax, int _id) { this.mapcontroll = m; this.Name = _name; this.step = _step; this.maxStep = stepMax; this.id = _id; string path = Application.dataPath + "/XML/MiniParts/" + _name + ".xml"; my = MyXML.ReaderXml(path); selfModles = Date.GetInstance.GetModels(new List <string>(my.Keys), _name); InitSelfModels(selfModles); //SetStep (_step); }