Skip to main content
The 2024 Developer Survey results are live! See the results

Questions tagged [lua]

Lua is a powerful, fast, lightweight, embeddable scripting language. It is dynamically typed, runs by interpreting bytecode, and has automatic garbage collection. Its speed is one of the main reasons it is widely used by the machine learning community. It is often referred to as an "extensible extension language".

5 votes
3 answers
994 views

Can variables passed to Pandoc be used in a lua-filter?

Does Pandoc expose variables set on the command line (pandoc -V foo=bar) to scripts running inside the built in lua filter environment? In other words if I run: pandoc -V foo=bar --lua-filter=...
0 votes
0 answers
13 views

ClickDetector not detecting input

For some reason my Click Detector that I had put inside of my Local Script / Script (tried both) doesn't detect when it's clicked on. Does anyone know what causes this? Code: local ts = game:...
1 vote
2 answers
38 views

Is it possible to Lua match string with an image name?

I got this script door = script.Parent function onChatted(msg, recipient, speaker) source = string.lower(speaker.Name) msg = string.lower(msg) -- thecharacter = script.Parent.TheCharacter if (msg ==...
3 votes
1 answer
127 views

neovim error: when using vim.fs.root(): attempt to call field 'root' (a nil value)

I'm just trying to set up a language server for a language that is not included in the popular lspconfig repo. I'm not a Lua developer and am only superficially familiar with Lua. I am looking at the ...
0 votes
1 answer
20 views

How can I use a parameter to alter which data my profile.Data is accessing?

local expType = tostring(type1) local expTypeStat = expType:gsub("Exp", "") local profileDataExpType = "profile.Data."..expType Here I want to change ...
1 vote
1 answer
22 views

Movement problems in pong clone using lua LOVE engine

I'm new to LOVE and I'm trying to make a pong clone to get familiar with the engine. I made the first paddle move using .isDown, but for some reason the second paddle is moving too. Any help is ...
0 votes
1 answer
20 views

Lua: How to load/install module json?

I try to use JSON in Lua - I am completely new to Lua. My code (test.lua) local json = require ("json") print "hello" My install (Debian 12) # luarocks install luajson Installing ...
1 vote
0 answers
20 views

Need the right flag, im not sure what it is

I'm a begginer in modding, specifically modding for The Binding of Isaac Repentance so Lua is new to me. The mod is supposed to upgrade your damage and size and lower your speed. Right now the dmg and ...
0 votes
1 answer
27 views

Lua Script for Reading CSV Produces Incorrect Output Format on Last Line

Issue Description I am writing a Lua script to read a CSV file and parse each line into a table. While processing the CSV file, I noticed that the output format of the last line is incorrect. Here is ...
-4 votes
0 answers
79 views

I am currently trying to develop a Roblox game;, would somebody be able to help me with locate a module?

This is a module script, it is in ServerScriptService: local PlayerDataHandler = {} local dataTemplate = { Race = "", Cash = 0, Inventory = {}, Level = 0, } local ...
1 vote
1 answer
29 views

Exp bar Gui not updating roblox studio

I have set up a basic exp system with exp, levels, and a Gui. I have the gui set to update when joining, and when gaining exp or a level, but it will only update when joining even though I'm using the ...
-4 votes
0 answers
28 views

Can sm1 help me and my friend with coding in roblox studio (lua) this is js for fun but we need help at like animations and a combat system type [closed]

we js need help with a combat system, and probably armour, we are not familiar with scripting on roblox studio We tried to make a combat system and it didnt turn out well, we need vfx, animations, and ...
2 votes
1 answer
29 views

What's the advantage and disadvantage that using string.format("str", ...) instead of "str":format(...) in Lua?

I found a interesting problem in Lua. Lua provides string.format function to format the string, and the first parameter of this function is the string you want to format. Coincidentally, Lua allows :...
0 votes
1 answer
24 views

I am attempting to pass an infobox value into a LUA module that outputting an answer based on the infobox value (FANDOM WIKIA)

I am working on a module that converts the value of a specific value into a new value when mutliplying it by a certain percentage. EX 100 * 1.3754 = 137.54. When I use the module, it spits out my ...
0 votes
0 answers
25 views

Freeswitch Lua API - how to get Channel State?

Using Freeswitch, I am desperately trying to get the channel Call State value in Lua. The Lua script is executed by posting an HTTP request to Verto.. This is the Lua code I have, so far: api = ...

15 30 50 per page
1
2 3 4 5
1522