Top "Lua" questions

Lua is a powerful, fast, lightweight, embeddable scripting language.

Lua - Current time in milliseconds

Is there a common way to get the current time in or with milliseconds? There is os.time(), but it …

time lua
Concatenation of strings in Lua

In many languages you can concatenate strings on variable assignment. I have a scenario, using the Lua programming language, where …

lua concatenation
Search for an item in a Lua list

If I have a list of items like this: local items = { "apple", "orange", "pear", "banana" } how do I check if "…

list lua lua-table
How to check if matching text is found in a string in Lua?

I need to make a conditional that is true if a particular matching text is found at least once in …

string lua conditional string-matching
How to read data from a file in Lua

I was wondering if there was a way to read data from a file or maybe just to see if …

lua
What is a good game engine that uses Lua?

I know Love2D and Corona SDK (for mobile devices). Is there any other game engines that use Lua you …

lua game-engine
Easiest way to make lua script wait/pause/sleep/block for a few seconds?

I cant figure out how to get lua to do any common timing tricks, such as sleep - stop all …

lua
Lua String replace

How would i do this? I got this: name = "^aH^ai" string.gsub(name, "^a", "") which should return "Hi", but …

string replace lua gsub lua-patterns
Lua os.execute return value

Is it possible to read the following from the local variable in Lua? local t = os.execute("echo 'test'") print(…

lua shellexecute
How do I append to a table in Lua

I'm trying to figure out the equivalent of: foo = [] foo << "bar" foo << "baz" I don't want …

lua lua-table