public static List <int> GetList(ref List <int> rList, long L, int nIndex) { try { long VM = FCLibHelper.fc_get_vm_ptr(L); if (rList == null) { rList = new List <int>(); } else { rList.Clear(); } long ptr = FCLibHelper.fc_get_param_ptr(L, nIndex); int nArraySize = FCLibHelper.fc_get_array_size(ptr); int[] buffer = new int[nArraySize]; FCLibHelper.fc_get_array_int(ptr, buffer, 0, nArraySize); rList.AddRange(buffer); } catch (Exception e) { Debug.LogException(e); } return(rList); }
public static int [] GetArray(ref int [] rList, long L, int nIndex) { long ptr = FCLibHelper.fc_get_param_ptr(L, nIndex); int nArraySize = FCLibHelper.fc_get_array_size(ptr); rList = new int[nArraySize]; FCLibHelper.fc_get_array_int(ptr, rList, 0, nArraySize); return(rList); }
public static int[] GetArray(ref int[] rList, long L, int nIndex) { try { long ptr = FCLibHelper.fc_get_param_ptr(L, nIndex); int nArraySize = FCLibHelper.fc_get_array_size(ptr); rList = new int[nArraySize]; FCLibHelper.fc_get_array_int(ptr, rList, 0, nArraySize); } catch (Exception e) { Debug.LogException(e); } return(rList); }
public static List <int> GetList(ref List <int> rList, long L, int nIndex) { if (rList == null) { rList = new List <int>(); } else { rList.Clear(); } long ptr = FCLibHelper.fc_get_param_ptr(L, nIndex); int nArraySize = FCLibHelper.fc_get_array_size(ptr); int[] buffer = new int[nArraySize]; FCLibHelper.fc_get_array_int(ptr, buffer, 0, nArraySize); rList.AddRange(buffer); return(rList); }