Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/Tencent/xLua
Browse files Browse the repository at this point in the history
  • Loading branch information
chexiongsheng committed Mar 16, 2020
2 parents 7495486 + 969f324 commit b5ab1c4
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions Assets/XLua/Src/DelegateBridge.cs
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ public virtual Delegate GetDelegateByType(Type type)

public static class HotfixDelegateBridge
{
#if UNITY_IPHONE && !UNITY_EDITOR
#if (UNITY_IPHONE || UNITY_TVOS) && !UNITY_EDITOR
[DllImport("__Internal", CallingConvention = CallingConvention.Cdecl)]
public static extern bool xlua_get_hotfix_flag(int idx);

Expand Down Expand Up @@ -117,7 +117,7 @@ public static void Set(int idx, DelegateBridge val)
DelegateBridge.DelegateBridgeList = newList;
}
DelegateBridge.DelegateBridgeList[idx] = val;
#if UNITY_IPHONE && !UNITY_EDITOR
#if (UNITY_IPHONE || UNITY_TVOS) && !UNITY_EDITOR
xlua_set_hotfix_flag(idx, val != null);
#endif
}
Expand Down
6 changes: 3 additions & 3 deletions Assets/XLua/Src/LuaDLL.cs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ namespace XLua.LuaDLL

public partial class Lua
{
#if (UNITY_IPHONE || UNITY_WEBGL || UNITY_SWITCH) && !UNITY_EDITOR
#if (UNITY_IPHONE || UNITY_TVOS || UNITY_WEBGL || UNITY_SWITCH) && !UNITY_EDITOR
const string LUADLL = "__Internal";
#else
const string LUADLL = "xlua";
Expand Down Expand Up @@ -292,7 +292,7 @@ public static string lua_tostring(IntPtr L, int index)
[DllImport(LUADLL, CallingConvention = CallingConvention.Cdecl)]
public static extern void lua_pushstring(IntPtr L, string str);
#else
public static void lua_pushstring(IntPtr L, string str) //业务使用
public static void lua_pushstring(IntPtr L, string str) //业务使用
{
if (str == null)
{
Expand Down Expand Up @@ -542,7 +542,7 @@ public static int lua_error(IntPtr L)
//[DllImport(LUADLL, CallingConvention = CallingConvention.Cdecl)]
//public static extern void xlua_pushbuffer(IntPtr L, byte[] buff);

//对于Unity,仅浮点组成的struct较多,这几个api用于优化这类struct
//对于Unity,仅浮点组成的struct较多,这几个api用于优化这类struct
[DllImport(LUADLL, CallingConvention = CallingConvention.Cdecl)]
public static extern bool xlua_pack_float2(IntPtr buff, int offset, float f1, float f2);
[DllImport(LUADLL, CallingConvention = CallingConvention.Cdecl)]
Expand Down

0 comments on commit b5ab1c4

Please sign in to comment.