public static T Get <T>(LuaReference Table, string Name) { int Top = GetTop(); Table.GetRef(); LL.lua_getfield(L, -1, Name); T Val = (T)Advanced.Get(L, 1, typeof(T)); SetTop(Top); return(Val); }
public static void Copy(LuaReference TableFrom, LuaReference TableTo, string FromName, string ToName = null) { if (ToName == null) { ToName = FromName; } TableTo.GetRef(); TableFrom.GetRef(); LL.lua_getfield(L, -1, FromName); LL.lua_setfield(L, -3, ToName); LL.lua_pop(L, 2); }