Example #1
0
    private static int CallGame(IntPtr L)
    {
        LuaScriptMgr.CheckArgsCount(L, 1);
        string luaString = LuaScriptMgr.GetLuaString(L, 1);

        CSharpInterface.CallGame(luaString);
        return(0);
    }
    private static int CallGame(IntPtr L)
    {
        int num = LuaDLL.lua_gettop(L);

        if (num == 1)
        {
            string luaString = LuaScriptMgr.GetLuaString(L, 1);
            CSharpInterface.CallGame(luaString);
            return(0);
        }
        if (num == 2)
        {
            uint     callId   = (uint)LuaScriptMgr.GetNumber(L, 1);
            LuaTable luaTable = LuaScriptMgr.GetLuaTable(L, 2);
            string   str      = CSharpInterface.CallGame(callId, luaTable);
            LuaScriptMgr.Push(L, str);
            return(1);
        }
        LuaDLL.luaL_error(L, "invalid arguments to method: com.tencent.pandora.CSharpInterface.CallGame");
        return(0);
    }