InitStart() 공개 메소드

public InitStart ( ) : void
리턴 void
예제 #1
0
 static int InitStart(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 1);
         LuaFramework.LuaManager obj = (LuaFramework.LuaManager)ToLua.CheckObject(L, 1, typeof(LuaFramework.LuaManager));
         obj.InitStart();
         return(0);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
 static int InitStart(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 2);
         LuaFramework.LuaManager obj  = (LuaFramework.LuaManager)ToLua.CheckObject <LuaFramework.LuaManager>(L, 1);
         System.Action           arg0 = (System.Action)ToLua.CheckDelegate <System.Action>(L, 2);
         obj.InitStart(arg0);
         return(0);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
예제 #3
0
        void OnInitialize()
        {
            LuaManager.InitStart();
            LuaManager.DoFile("Logic/Game");         //加载游戏
            LuaManager.DoFile("Logic/Network");      //加载网络
            NetManager.OnInit();                     //初始化网络
            Util.CallMethod("Game", "OnInitOK");     //初始化完成

            initialize = true;

            /*
             * //类对象池测试
             * var classObjPool = ObjPoolManager.CreatePool<TestObjectClass>(OnPoolGetElement, OnPoolPushElement);
             * //方法1
             * //objPool.Release(new TestObjectClass("abcd", 100, 200f));
             * //var testObj1 = objPool.Get();
             *
             * //方法2
             * ObjPoolManager.Release<TestObjectClass>(new TestObjectClass("abcd", 100, 200f));
             * var testObj1 = ObjPoolManager.Get<TestObjectClass>();
             *
             * Debugger.Log("TestObjectClass--->>>" + testObj1.ToString());
             *
             * //游戏对象池测试
             * var prefab = Resources.Load("TestGameObjectPrefab", typeof(GameObject)) as GameObject;
             * var gameObjPool = ObjPoolManager.CreatePool("TestGameObject", 5, 10, prefab);
             *
             * var gameObj = Instantiate(prefab) as GameObject;
             * gameObj.name = "TestGameObject_01";
             * gameObj.transform.localScale = Vector3.one;
             * gameObj.transform.localPosition = Vector3.zero;
             *
             * ObjPoolManager.Release("TestGameObject", gameObj);
             * var backObj = ObjPoolManager.Get("TestGameObject");
             * backObj.transform.SetParent(null);
             *
             * Debug.Log("TestGameObject--->>>" + backObj);*/
        }
예제 #4
0
        void OnInitialize()
        {
            LuaManager.InitStart();

            LuaManager.StartGame();
        }