I've been trying to find a way to return multiple values from a Java method in LuaJ. That is, return multiple values from Java to be retrieved inside Lua code.
Once again... What I mean is:
public LuaValue call() {
Dimension size = guiConsole.getSize();
int width = LuaValue.valueOf(size.width), height = LuaValue.valueOf(size.height);
return width, height; // This obviously wouldn't work, but this is the functionality I'm after
}
So that I then from Lua code can do:
width, height = getSize()
Successfully retrieving both the width and the height.
Best regards,