|
> I don't understand why this isn't working: http://pastebin.com/kGX5Eay0The manual says that access to metatables are raw:
> When asking for #t, it should check the metatable "meta" for a __len
> method. But this doesn't seem to invoke "meta"'s __index metamethod.
metatable(obj)[event]
should be read as
rawget(getmetatable(obj) or {}, event)
http://www.lua.org/manual/5.2/manual.html#2.4