Call Java class in Lua Android
Posted: Thu Oct 24, 2019 8:47 pm
Hi, I successfully build apk using this repository.
https://bitbucket.org/MartinFelis/love- ... /src/11.2/
Now I am trying to use the bluetooth function. I have the code to a previously project, to make the connection.
But I no have any idea how to call the class in lua.
I used a little FFI in my projects, but I don't know how to call JNI.
Search in the forum I found this Library https://bitbucket.org/bartbes/jniwrap
I honestly don't know how it works and the project structure, but I receive the following error, using test.lua in this repository to call ExtraTest.java
I/SDL/APP: [LOVE] ERROR: test.lua:10: undefined symbol: getGlobalEnv
How should I do to call a Java class in Lua code in Android.
https://bitbucket.org/MartinFelis/love- ... /src/11.2/
Now I am trying to use the bluetooth function. I have the code to a previously project, to make the connection.
But I no have any idea how to call the class in lua.
I used a little FFI in my projects, but I don't know how to call JNI.
Search in the forum I found this Library https://bitbucket.org/bartbes/jniwrap
I honestly don't know how it works and the project structure, but I receive the following error, using test.lua in this repository to call ExtraTest.java
Code: Select all
--main.lua
require "test"
How should I do to call a Java class in Lua code in Android.