Exemple #1
0
 static public int Get_s(IntPtr l)
 {
     try {
                     #if DEBUG
         var    method     = System.Reflection.MethodBase.GetCurrentMethod();
         string methodName = GetMethodName(method);
                     #if UNITY_5_5_OR_NEWER
         UnityEngine.Profiling.Profiler.BeginSample(methodName);
                     #else
         Profiler.BeginSample(methodName);
                     #endif
                     #endif
         int argc = LuaDLL.lua_gettop(l);
         if (matchType(l, argc, 1, typeof(UnityEngine.GameObject)))
         {
             UnityEngine.GameObject a1;
             checkType(l, 1, out a1);
             var ret = DropEventListener.Get(a1);
             pushValue(l, true);
             pushValue(l, ret);
             return(2);
         }
         else if (matchType(l, argc, 1, typeof(UnityEngine.Transform)))
         {
             UnityEngine.Transform a1;
             checkType(l, 1, out a1);
             var ret = DropEventListener.Get(a1);
             pushValue(l, true);
             pushValue(l, ret);
             return(2);
         }
         else if (matchType(l, argc, 1, typeof(UnityEngine.GameObject), typeof(SLua.LuaTable)))
         {
             UnityEngine.GameObject a1;
             checkType(l, 1, out a1);
             SLua.LuaTable a2;
             checkType(l, 2, out a2);
             var ret = DropEventListener.Get(a1, a2);
             pushValue(l, true);
             pushValue(l, ret);
             return(2);
         }
         else if (matchType(l, argc, 1, typeof(UnityEngine.Transform), typeof(SLua.LuaTable)))
         {
             UnityEngine.Transform a1;
             checkType(l, 1, out a1);
             SLua.LuaTable a2;
             checkType(l, 2, out a2);
             var ret = DropEventListener.Get(a1, a2);
             pushValue(l, true);
             pushValue(l, ret);
             return(2);
         }
         pushValue(l, false);
         LuaDLL.lua_pushstring(l, "No matched override function Get to call");
         return(2);
     }
     catch (Exception e) {
         return(error(l, e));
     }
             #if DEBUG
     finally {
                     #if UNITY_5_5_OR_NEWER
         UnityEngine.Profiling.Profiler.EndSample();
                     #else
         Profiler.EndSample();
                     #endif
     }
             #endif
 }
Exemple #2
0
 static public DropEventListener Get(Transform tf, LuaTable target)
 {
     return(DropEventListener.Get(tf.gameObject, target));
 }
Exemple #3
0
 static public DropEventListener Get(Transform tf)
 {
     return(DropEventListener.Get(tf.gameObject, null));
 }
Exemple #4
0
 static public DropEventListener Get(GameObject go)
 {
     return(DropEventListener.Get(go, null));
 }