All Questions
216
questions
3
votes
1
answer
46
views
Input from user in Luaj
Recently found out about luaj, it is really cool that hey implemented lua in java.
And now I am wondering how to get user input for io.read()
As I saw on GitHub, in Globals.java there is this code:
...
1
vote
1
answer
129
views
Java FFM, how to link a java object with a C struct?
I'd like to know how I can "link" a C struct to an object in Java with the FFM library.
I have a game in Java, and I'd ultimately like to allow users to create Luau scripts to interface with ...
0
votes
1
answer
164
views
Running Java files with Neovim ide
I normally work on java projects and i recentely shifted to neovim from vscode, i have my lsp setup for java and everything but I cant run my files with just "java file.java" since i am ...
2
votes
1
answer
554
views
Neovim configuration setup with none_ls
I'm configuring my none-ls.lua file for neovim right now and I'm trying to to find the best builtin formatting for java. But there are too many different types of java formatting builtins out there. ...
0
votes
0
answers
56
views
Using Java Interfaces in Lua Script with LuaJ
I have a method like below in Java for starting animation sequences
public void addAnimationSequence(final Vector3[] targetOffset, int duration, final AnimationFinishedListener ...
2
votes
1
answer
502
views
nvim: compile/run code based on filetype in function from keymap using lua
I'm trying to map my F12 key to compile and run code in neovim using the term command. I've been able to get it to work for java files, but only if I opened nvim from the same location as the file I'm ...
0
votes
0
answers
919
views
How can you include referenced libraries in neovim lsp using jdtls?
I have a java library in a folder in my home folder (on linux) and I've been trying to edit my neovim config to let it be available for any java project. I'm having trouble finding the exact config I ...
1
vote
0
answers
239
views
Interfaces in Lua (mocking dependencies)
Preamble
I am writing Lua code to control virtual devices attached to a virtual computer. I do not have control over the "component" library/dependency.
-- Component is used to access other ...
-1
votes
1
answer
170
views
Lua os.time function
so i’m trying to get some values from lua and javascript, i’m using os.time for lua and Date.now for java, but when creating these values they are a little bit different, like java has 3 more digits ...
1
vote
1
answer
95
views
How can I use a list as a function parameter with LuaJ?
So, I have a function in a Lua script that takes an parameter.
testFunction = function(listIn)
for i, obj in ipairs(listIn) do
print(i)
end
end
This parameter is obviously meant to be ...
0
votes
0
answers
55
views
How To find Distance between Npcs humanoids so they can chase eachother?
I have a testing studio place where I created Npcs to chase each other and they do that by looping through workspace to find other humanoids besides their own and chasing them. The problem is I use ...
0
votes
0
answers
192
views
Starting up with Luaj
Are there any good Luaj tutorials?
I have been working on a game using Lua for for mi finals but my profesor wants me to implement my code to
java.
I already read the Luaj manual but i found it quite ...
0
votes
0
answers
111
views
aes128cbc encryption method in java code switch to lua code but have difference
package com.example;
import org.apache.commons.codec.binary.Base64;
import javax.crypto.BadPaddingException;
import javax.crypto.Cipher;
import javax.crypto.IllegalBlockSizeException;
import javax....
0
votes
1
answer
497
views
Intermediate HTTP call to external service in the APISIX Serverless
How to send an HTTP request to external service in the APISIX Gateway serverless-pre-function, I am trying below but getting an error
"serverless-pre-function": {
"disable": ...
2
votes
1
answer
1k
views
calling a Redis function(loaded Lua script) using Lettuce library
I am using Java, Spring-Boot, Redis 7.0.4, and lettuce 6.2.0.RELEASE.
I wrote a Lua script as below:
#!lua
name = updateRegisterUserJobAndForwardMsg
function updateRegisterUserJobAndForwardMsg (KEYS, ...