Interface LuaFunction


public interface LuaFunction
Interface for functions implemented in Java.
  • Method Summary

    Modifier and Type
    Method
    Description
    LuaValue @Nullable []
    call(Lua L, LuaValue[] args)
    Implements the function body
  • Method Details

    • call

      LuaValue @Nullable [] call(Lua L, LuaValue[] args)
      Implements the function body

      Unlike JFunction.__call(Lua), before actually calling this function, the library converts all the arguments to LuaValues and pops them off the stack.

      Parameters:
      L - the Lua state
      args - the arguments
      Returns:
      the return values (nullable)