public string[] ToStringArray(int index) { int length = LuaAPI.lua_objlen(this.m_lua, index); string[] array = new string[length]; for (int i = 0; i < length; i++) { RawGetI(index, i + 1); array[i] = (string)ToString(-1); Pop(1); } return(array); }
public bool[] ToBoolArray(int index) { int length = LuaAPI.lua_objlen(this.m_lua, index); bool[] array = new bool[length]; for (int i = 0; i < length; i++) { RawGetI(index, i + 1); array[i] = (bool)ToBoolean(-1); Pop(1); } return(array); }
public int[] ToIntArray(int index) { int length = LuaAPI.lua_objlen(this.m_lua, index); int[] array = new int[length]; for (int i = 0; i < length; i++) { RawGetI(index, i + 1); array[i] = (int)ToInteger(-1); Pop(1); } return(array); }
public float[] ToFloatArray(int index) { int length = LuaAPI.lua_objlen(this.m_lua, index); float[] array = new float[length]; for (int i = 0; i < length; i++) { RawGetI(index, i + 1); array[i] = (float)ToNumber(-1); Pop(1); } return(array); }
public int RawLen(int index) { return(LuaAPI.lua_objlen(this.m_lua, index)); }