Skip to main content

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".

lua
-1 votes
0 answers
19 views

Can nginx's njs (or Lua?) be used to replace a header with that header's SHA-512?

I need to replace one log field, from nginx.conf, with its SHA-512 hash, for security reasons. I'd prefer to do this with njs, but would consider Lua. However, the only way I know of to modify a log ...
dstromberg's user avatar
  • 7,039
-2 votes
0 answers
53 views

sol::function callback works when called in Lua but doesn't exist in C++ [closed]

I have a problem with sol::function that doesn't make any sense. I have this struct that is supposed to hold a sol2 Lua callback function. It has a method that allows Lua to pass in a callback to the ...
Aatos Tapper's user avatar
0 votes
0 answers
21 views

Input order of points changes the outcome of Delaunay Triangulation

Recently I have learnt about the Delaunay Triangulation and using the Bowyer-Watson algorithm to solve it. When implementing, I followed along from the wikipedia pseudocode and other sources to create ...
Thomasssb1's user avatar
-4 votes
0 answers
24 views

My code is not working even though I followed a tutorial [closed]

so my code is supposed to make a sphere look at the player and follow them with the decal facing them, however, the issue is that sphere, in every instance, has the error "unkown global 'sphere'. ...
Ted Mcaferty's user avatar
0 votes
0 answers
25 views

Script not detecting when a player with a set ID joins. Luau

For some reason a simple script that I wrote, that should call a function whenever a player joins, which after that checks if the players ID is one of the either. game.Players.PlayerAdded:Connect(...
Relaxing Gaming's user avatar
0 votes
0 answers
18 views

Is there a way to detect if local players character is touching the hitbox instead of the victim? Luau

Main question for me is can I make it so that it can access the local players character from a variable given in a module script? I can't seem to access the character of it, even though it still IS ...
Relaxing Gaming's user avatar
0 votes
0 answers
14 views

Can`t get constraint.HasConstraints working in Lua gmod

I`m writing a gmod lua script which checks if there are constraints for prop spawned by user (like ropes), but it always return false even if I spawn constrained props if SERVER then hook.Add(&...
Тимур Сенников's user avatar
0 votes
0 answers
36 views

Prevent duplication entry based on amount

So I'm writing an inventory for a game in lua, but I have some issues when it saves the inventory. The function code is as follows function SaveInventory(source, offline) local source = source ...
Avanae's user avatar
  • 21
0 votes
0 answers
60 views

Lua function: 'type', recreated in Luau

I need help with CheckType. How can I make it check: Enum. (Enum is a userdata, but it doesn't work; Enum is in Luau.) (This is me asking for help in the Language: Luau (Roblox)) When I test Enum, it ...
Valkyrie's user avatar
0 votes
1 answer
74 views

How to combine two logitech scripts?

Im trying to put the following 2 scripts together so that they can run at the same exact time. function OnEvent(event, arg) if EnableRCS ~= false then if IsMouseButtonPressed(3) then -- ...
censori's user avatar
1 vote
1 answer
53 views

Passing arguments through a RemoteEvent in Roblox

I'm currently trying to make a message system in Roblox. The server should be able to send a message via a RemoteEvent, and the client should be able to accept it by displaying the message on a GUI ...
Robin Bubeník's user avatar
0 votes
0 answers
30 views

Basketball not bouncing properly in Lua in Roblox Studio (I am making a game in Roblox Studio)

As the title clearly suggests, I am making a basketball game in roblox so I have recently been trying to make my basketball part, named "B-Ball" bounce in a continuous motion. This can be ...
Bro Ski's user avatar
0 votes
1 answer
41 views

Stamina bar going from 100 to 0 for no reason, Stamina value not getting any interactions

For some reason whenever I launch my experience, like a second or a half passes and the bar goes from full to empty. I also can't make any interactions with the value. (example: whenever I try to make ...
Relaxing Gaming's user avatar
0 votes
0 answers
32 views

Does executing a Lua script in Redis block the entire Redis server or just the database being accessed?

Details: Atomic Operations: I understand that Lua scripts in Redis are executed atomically. However, I need clarification on whether the atomicity affects only the Redis database being accessed by the ...
Gokulraj S's user avatar
1 vote
2 answers
46 views

All ModuleScript variables == nil

For some reason, my local variables in the module script all seem to be nil, with no exact explanation for it, or solution. Local Script (Stamina bar Script): local ms = require(game.ReplicatedStorage....
Relaxing Gaming's user avatar

15 30 50 per page
1
2 3 4 5
1521