Half-Edge data structure for Lua