parent
8fd4f2ed5d
commit
4422c72806
|
@ -8,7 +8,7 @@ local ManagerNames = {
|
|||
"Net/IndicationManager",
|
||||
--数据中心管理
|
||||
"DataCenterService/DataCenterManager",
|
||||
"DataCenterService/ThinkingAnalyticsManager",
|
||||
--"DataCenterService/ThinkingAnalyticsManager",
|
||||
"DataCenterService/TapDBManager",
|
||||
"DataCenterService/BuglyManager",
|
||||
"DataCenterService/CustomEventManager",
|
||||
|
|
|
@ -83,12 +83,20 @@ end
|
|||
|
||||
--应用程序暂停/恢复
|
||||
function Game.OnApplicationPause(pauseStatus)
|
||||
Log("Game.OnApplicationPause:"..tostring(pauseStatus))
|
||||
LogError("Game.OnApplicationPause:"..tostring(pauseStatus))
|
||||
if pauseStatus==true then
|
||||
LogError("11111111111111111111111111111111111111111111111111111111111111111")
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
--应用程序获得焦点/失去焦点
|
||||
function Game.OnApplicationFocus(hasFocus)
|
||||
Log("Game.OnApplicationFocus:"..tostring(hasFocus))
|
||||
LogError("Game.OnApplicationFocus:"..tostring(hasFocus))
|
||||
if hasFocus then
|
||||
LogError("222222222222222222222222222222222222")
|
||||
--Game.GlobalEvent:DispatchEvent(Protocal.Exception, self)
|
||||
end
|
||||
end
|
||||
|
||||
--应用程序退出
|
||||
|
|
|
@ -122,7 +122,7 @@ public class GameStart : MonoBehaviour
|
|||
{
|
||||
yield return App.Instance.Initialize();
|
||||
// 初始化数数
|
||||
App.TAMgr.Init();
|
||||
//App.TAMgr.Init();
|
||||
//App.Instance.Initialize();
|
||||
UpdateManager.Instance.StartUp();
|
||||
}
|
||||
|
|
|
@ -30,6 +30,7 @@ public class GameLogic_AppConstWrap
|
|||
L.RegVar("Channel_ID", get_Channel_ID, set_Channel_ID);
|
||||
L.RegVar("PIXELTOWORLD", get_PIXELTOWORLD, set_PIXELTOWORLD);
|
||||
L.RegVar("EncyptBytesLength", get_EncyptBytesLength, set_EncyptBytesLength);
|
||||
L.RegVar("EncyptKey", get_EncyptKey, set_EncyptKey);
|
||||
L.RegVar("DOWNLOAD_URL_FORMAT", get_DOWNLOAD_URL_FORMAT, null);
|
||||
L.RegVar("Platform", get_Platform, set_Platform);
|
||||
L.RegVar("FilePathEx", get_FilePathEx, set_FilePathEx);
|
||||
|
@ -410,6 +411,20 @@ public class GameLogic_AppConstWrap
|
|||
}
|
||||
}
|
||||
|
||||
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
||||
static int get_EncyptKey(IntPtr L)
|
||||
{
|
||||
try
|
||||
{
|
||||
LuaDLL.lua_pushstring(L, GameLogic.AppConst.EncyptKey);
|
||||
return 1;
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
return LuaDLL.toluaL_exception(L, e);
|
||||
}
|
||||
}
|
||||
|
||||
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
||||
static int get_DOWNLOAD_URL_FORMAT(IntPtr L)
|
||||
{
|
||||
|
@ -1522,6 +1537,21 @@ public class GameLogic_AppConstWrap
|
|||
}
|
||||
}
|
||||
|
||||
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
||||
static int set_EncyptKey(IntPtr L)
|
||||
{
|
||||
try
|
||||
{
|
||||
string arg0 = ToLua.CheckString(L, 2);
|
||||
GameLogic.AppConst.EncyptKey = arg0;
|
||||
return 0;
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
return LuaDLL.toluaL_exception(L, e);
|
||||
}
|
||||
}
|
||||
|
||||
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
||||
static int set_Platform(IntPtr L)
|
||||
{
|
||||
|
|
|
@ -11,6 +11,8 @@ public class GameLogic_ConfigManagerWrap
|
|||
L.RegFunction("SetNetInfo", SetNetInfo);
|
||||
L.RegFunction("GetConfigInfo", GetConfigInfo);
|
||||
L.RegFunction("GetConfigNetInfo", GetConfigNetInfo);
|
||||
L.RegFunction("IsSettingActive", IsSettingActive);
|
||||
L.RegFunction("GetSettingValue", GetSettingValue);
|
||||
L.RegFunction("New", _CreateGameLogic_ConfigManager);
|
||||
L.RegFunction("__tostring", ToLua.op_ToString);
|
||||
L.EndClass();
|
||||
|
@ -109,5 +111,41 @@ public class GameLogic_ConfigManagerWrap
|
|||
return LuaDLL.toluaL_exception(L, e);
|
||||
}
|
||||
}
|
||||
|
||||
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
||||
static int IsSettingActive(IntPtr L)
|
||||
{
|
||||
try
|
||||
{
|
||||
ToLua.CheckArgsCount(L, 2);
|
||||
GameLogic.ConfigManager obj = (GameLogic.ConfigManager)ToLua.CheckObject<GameLogic.ConfigManager>(L, 1);
|
||||
string arg0 = ToLua.CheckString(L, 2);
|
||||
bool o = obj.IsSettingActive(arg0);
|
||||
LuaDLL.lua_pushboolean(L, o);
|
||||
return 1;
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
return LuaDLL.toluaL_exception(L, e);
|
||||
}
|
||||
}
|
||||
|
||||
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
||||
static int GetSettingValue(IntPtr L)
|
||||
{
|
||||
try
|
||||
{
|
||||
ToLua.CheckArgsCount(L, 2);
|
||||
GameLogic.ConfigManager obj = (GameLogic.ConfigManager)ToLua.CheckObject<GameLogic.ConfigManager>(L, 1);
|
||||
string arg0 = ToLua.CheckString(L, 2);
|
||||
string o = obj.GetSettingValue(arg0);
|
||||
LuaDLL.lua_pushstring(L, o);
|
||||
return 1;
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
return LuaDLL.toluaL_exception(L, e);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -14,6 +14,7 @@ public class GameLogic_NetworkManagerWrap
|
|||
L.RegFunction("SendGetHttp", SendGetHttp);
|
||||
L.RegFunction("SendHttpPost_Raw_Lua", SendHttpPost_Raw_Lua);
|
||||
L.RegFunction("SendHttpPost_Json_Lua", SendHttpPost_Json_Lua);
|
||||
L.RegFunction("PostData", PostData);
|
||||
L.RegFunction("SendHttpPost_Raw_CSharp", SendHttpPost_Raw_CSharp);
|
||||
L.RegFunction("SendHttpPost_Json_CSharp", SendHttpPost_Json_CSharp);
|
||||
L.RegFunction("HttpPost_Co", HttpPost_Co);
|
||||
|
@ -150,6 +151,29 @@ public class GameLogic_NetworkManagerWrap
|
|||
}
|
||||
}
|
||||
|
||||
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
||||
static int PostData(IntPtr L)
|
||||
{
|
||||
try
|
||||
{
|
||||
ToLua.CheckArgsCount(L, 7);
|
||||
GameLogic.NetworkManager obj = (GameLogic.NetworkManager)ToLua.CheckObject<GameLogic.NetworkManager>(L, 1);
|
||||
string arg0 = ToLua.CheckString(L, 2);
|
||||
string arg1 = ToLua.CheckString(L, 3);
|
||||
LuaFunction arg2 = ToLua.CheckLuaFunction(L, 4);
|
||||
System.Action<string> arg3 = (System.Action<string>)ToLua.CheckDelegate<System.Action<string>>(L, 5);
|
||||
System.Action arg4 = (System.Action)ToLua.CheckDelegate<System.Action>(L, 6);
|
||||
LuaFunction arg5 = ToLua.CheckLuaFunction(L, 7);
|
||||
System.Collections.IEnumerator o = obj.PostData(arg0, arg1, arg2, arg3, arg4, arg5);
|
||||
ToLua.Push(L, o);
|
||||
return 1;
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
return LuaDLL.toluaL_exception(L, e);
|
||||
}
|
||||
}
|
||||
|
||||
[MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))]
|
||||
static int SendHttpPost_Raw_CSharp(IntPtr L)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue