Lua is a powerful, fast, lightweight, embeddable scripting language. Lua is widely used as a scripting language by game programmers, perhaps owing to how easy it is to embed, its fast execution, and its short learning curve.

learn more… | top users | synonyms

1
vote
1answer
43 views

Scripting: to block or not to block

Context: I'm making a little "program your robot army" sort of game in Java in which the player writes Lua scripts (which are then run by LuaJ) to program their robots to do stuff. So far there are ...
0
votes
1answer
25 views

In ROBLOX, how can I check what is in front of me?

In ROBLOX Studio I need to check what part is in front of the model Freddy. I need to set the variable called thingInFront to the part that is in front of the model Freddy so that I can decide ...
0
votes
1answer
137 views

Garry's Mod HatsChat2 chat colors permissions messed up?

So I'm making a garry's mod server and I'm trying to work on my chat box addon that I installed and was working on that only premium and superadmin can use colors in the chat and only want them to be ...
1
vote
0answers
41 views

Passing an SDL KeyboardState(Uint8*) to Lua

I'm working on my first big project and I've decided to integrate Lua with my C++ framework. Everything's worked out so far, but the only way I've managed to pass the SDL_GetKeyboardState(NULL) array ...
1
vote
0answers
166 views

Determine required camera pitch/yaw change based on mouse movement and roll?

I'm sure this is going to be a pretty simple answer but I can't quite figure it out on my own. Each frame, I'm getting the mouse's distance from the center of the screen (left/up is positive) and ...
0
votes
0answers
55 views

How to implement Lua thread for Sleep function

I am running into a problem in my game engine right now. I want to be able to call Sleep(number_of_seconds) from .lua file (1 only) and halt the execution of the lua file, WHILE the game is running ...
0
votes
0answers
86 views

Calculate future 3D Position of object(Unit)?

I've looked around and almost all examples is see have a velocity vector which I do not have, or at this point am unable to figure out. Im trying to find the 3D position where i can launch a trap in ...
0
votes
0answers
78 views

How do you use Lua with several game objects / components?

I haven't found a lot of information / tutorials on this subject, so I figured I'd ask here. I would like to use Lua-Alchemy (the Flash port of Lua) to be able to load scripts and run console-like ...
0
votes
0answers
238 views

Touch-detection in cocos2d-x (Lua): Catering for bounding boxes and scale factor

I am trying to write an app in Cocos2d-x with Lua. I have a sprite that I have added directly to a scene, and now I want to detect touches on the sprite. Right now, my touch begin function looks as ...