string mMapName; //地图名 public void Init(mTonBehaviour s) { btn_ok = (UIEventListener)s.get_object("btn_ok", "UIEventListener"); mType = s.get_int("mType"); mMapName = s.get_string("mMapName"); }
void InitFields() { mTonBehaviour mton = (mTonBehaviour)target; if (!string.IsNullOrEmpty(mton.mTemplate)) { string szPath = Application.dataPath + "/mTon/Editor/Config/" + mton.mTemplate + ".txt"; mFields.Clear(); if (!File.Exists(szPath)) { return; } string file = File.ReadAllText(szPath); mFields = mTonFieldInfo.Deserilize(file); } }
public virtual void onserilizeRoot(mTonBehaviour mTon) { }
GameObject mModel_0; //1 v 1 模式 public void Init(mTonBehaviour s) { mModel_0 = (GameObject)s.get_object("mModel_0", "GameObject"); }
public override void onserilizeRoot(mTonBehaviour mTon) { base.onserilizeRoot(mTon); Init(mTon); seriliszeFrame(); }
UIEventListener btn_login; //登录按钮 public void Init(mTonBehaviour s) { btn_login = (UIEventListener)s.get_object("btn_login", "UIEventListener"); }
public override void onserilizeRoot(mTonBehaviour mTon) { base.onserilizeRoot(mTon); Init(mTon); InitModel(); }
GameObject mGoLoginFrame; //登录界面 public void Init(mTonBehaviour s) { mUIRoot = (UIRoot)s.get_object("mUIRoot", "UIRoot"); mGoLoginFrame = (GameObject)s.get_object("mGoLoginFrame", "GameObject"); }