static int InstancePrefab(IntPtr L)
    {
        try
        {
            int count = LuaDLL.lua_gettop(L);

            if (count == 3)
            {
                string      arg0 = ToLua.CheckString(L, 1);
                string      arg1 = ToLua.CheckString(L, 2);
                LuaFunction arg2 = ToLua.CheckLuaFunction(L, 3);
                ResourceLoad.InstancePrefab(arg0, arg1, arg2);
                return(0);
            }
            else if (count == 4)
            {
                string arg0 = ToLua.CheckString(L, 1);
                string arg1 = ToLua.CheckString(L, 2);
                UnityEngine.Transform arg2 = (UnityEngine.Transform)ToLua.CheckObject <UnityEngine.Transform>(L, 3);
                LuaFunction           arg3 = ToLua.CheckLuaFunction(L, 4);
                ResourceLoad.InstancePrefab(arg0, arg1, arg2, arg3);
                return(0);
            }
            else
            {
                return(LuaDLL.luaL_throw(L, "invalid arguments to method: ResourceLoad.InstancePrefab"));
            }
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e));
        }
    }