//---------------------------------------------------------------------------- public static byte[] GetArray(ref byte[] rList, long L, int nIndex) { long ptr = FCLibHelper.fc_get_param_ptr(L, nIndex); int nArraySize = FCLibHelper.fc_get_array_size(ptr); rList = new byte[nArraySize]; FCLibHelper.fc_get_array_byte(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 <Rect> GetList(ref List <Rect> rList, long L, int nIndex) { if (rList == null) { rList = new List <Rect>(); } else { rList.Clear(); } long ptr = FCLibHelper.fc_get_param_ptr(L, nIndex); int nArraySize = FCLibHelper.fc_get_array_size(ptr); Rect[] buffer = new Rect[nArraySize]; FCLibHelper.fc_get_array_rect(ptr, buffer, 0, nArraySize); rList.AddRange(buffer); return(rList); }
public static string[] GetArray(ref string[] 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 string[nArraySize]; for (int i = 0; i < nArraySize; ++i) { long item_ptr = FCLibHelper.fc_get_array_node_temp_ptr(ptr, i); string item = FCLibHelper.fc_get_value_string_a(item_ptr); rList[i] = item; } } catch (Exception e) { Debug.LogException(e); } return(rList); }
public static UnityEngine.Touch[] GetArray(ref UnityEngine.Touch[] 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 UnityEngine.Touch[nArraySize]; for (int i = 0; i < nArraySize; ++i) { long item_ptr = FCLibHelper.fc_get_array_node_temp_ptr(ptr, i); UnityEngine.Touch item = FCGetObj.GetObj <UnityEngine.Touch>(item_ptr); rList[i] = item; } } catch (Exception e) { Debug.LogException(e); } return(rList); }
public static AccelerationEvent[] GetArray(ref AccelerationEvent[] 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 AccelerationEvent[nArraySize]; for (int i = 0; i < nArraySize; ++i) { long item_ptr = FCLibHelper.fc_get_array_node_temp_ptr(ptr, i); AccelerationEvent item = FCGetObj.GetObj <AccelerationEvent>(item_ptr); rList[i] = item; } } catch (Exception e) { Debug.LogException(e); } return(rList); }
public static List <string> GetList(ref List <string> rList, long L, int nIndex) { if (rList == null) { rList = new List <string>(); } else { rList.Clear(); } long ptr = FCLibHelper.fc_get_param_ptr(L, nIndex); int nArraySize = FCLibHelper.fc_get_array_size(ptr); for (int i = 0; i < nArraySize; ++i) { long item_ptr = FCLibHelper.fc_get_array_node_temp_ptr(ptr, i); rList.Add(FCLibHelper.fc_get_value_string_a(item_ptr)); } return(rList); }
public static System.Type[] GetArray(ref System.Type[] rList, long L, int nIndex) { try { long VM = FCLibHelper.fc_get_vm_ptr(L); long ptr = FCLibHelper.fc_get_param_ptr(L, nIndex); int nArraySize = FCLibHelper.fc_get_array_size(ptr); rList = new System.Type[nArraySize]; for (int i = 0; i < nArraySize; ++i) { long item_ptr = FCLibHelper.fc_get_array_node_temp_ptr(VM, ptr, i); System.Type item = FCGetObj.GetObj <System.Type>(item_ptr); rList[i] = item; } } catch (Exception e) { Debug.LogException(e); } return(rList); }
//---------------------------------------------------------------------------- public static List <bool> GetList(ref List <bool> rList, long L, int nIndex) { if (rList == null) { rList = new List <bool>(); } else { rList.Clear(); } long ptr = FCLibHelper.fc_get_param_ptr(L, nIndex); int nArraySize = FCLibHelper.fc_get_array_size(ptr); //for(int i = 0; i< nArraySize; ++i) //{ // long pNode = FCLibHelper.fc_get_array_node_temp_ptr(ptr, i); // rList.Add(FCLibHelper.fc_get_value_bool(pNode)); //} bool[] buffer = new bool[nArraySize]; FCLibHelper.fc_get_array_bool(ptr, buffer, 0, nArraySize); rList.AddRange(buffer); return(rList); }
public static List <Vector2> GetList(ref List <Vector2> rList, long L, int nIndex) { try { if (rList == null) { rList = new List <Vector2>(); } else { rList.Clear(); } long ptr = FCLibHelper.fc_get_param_ptr(L, nIndex); int nArraySize = FCLibHelper.fc_get_array_size(ptr); Vector2[] buffer = new Vector2[nArraySize]; FCLibHelper.fc_get_array_vector2(ptr, buffer, 0, nArraySize); rList.AddRange(buffer); } catch (Exception e) { Debug.LogException(e); } return(rList); }