Rbx.lua - A lua-written Roblox API wrapper (Alpha 1.0.2)

About:
I believe creating Roblox group bots or similar shouldn’t be limited to only a few select programming languages that might not be easy to learn. This is a small project as of release, so there’s 100% going to be bugs that I haven’t discovered. If the project actually begins to pick up a following, I’ll begin adding a lot of new features and making my code more efficient.

Links:

How to install:

  • First off, we need to install Luvit. Follow the steps there provided for your specific platform.
  • Now we need to install the dependencies, this part is pretty easy once you’ve installed Luvit.
    Simply run lit install iiToxicity/rbx.lua to install the dependencies.

How to get up and running:
Make sure to check out the Discord or Documentation for any help required.

I’m going to create a file named test.lua for an example. Your file directory should look like this or similar. Let’s get started by creating the client!

local roblox = require("Roblox");
local client = roblox.client();

Now, we must authorize the client to get to the next stage. The authorization is your .ROBLOSECURITY cookie. You should always use an alternate account for stuff like this to prevent potential damage from being done on your main account with faulty code or similar. You’ll need to google around to get the cookie, as there are so many varieties of browsers. Once you have it, it’s super straightforward from here.

  • Have your cookie?
client:run(".ROBLOSECURITY HERE")
  • Don’t wanna use this with an account?
client:run() --> This will also work, but it'll take away all functions that require authorization.
  • But wait, how do I run functions now?

You’ll need to register a ready callback like this:

client:on("ready",function()
    print("Client ready");
end)

You can then construct code inside the callback with our documentation.

Always remember, if you still need help feel free to join our Discord for support.

Here’s a final example:

local roblox = require("Roblox");
local client = roblox.client();

client:on("ready",function()
    local success,response = client.group.shout(123456,"A group shout.");
    print(success,response);
end)

client:run("ROBLOSECURITY HERE")

Have fun developing! If you experience any issues, please report them to me.

38 Likes

Looks really cool! Great job. :slight_smile:

2 Likes

Looks interesting! I’m used to using noblox.js but I’ll give this one a shot.

1 Like

JavaScript isn’t too difficult to learn, but this is very cool!
Have you considered adding functionality for trading limiteds?

1 Like

I’m pretty down to add functions like that, but it wouldn’t be worth it if people don’t end up using the system.

1 Like

Looks great for just being released! This is very useful for some groups like SCP sites, hotels and more! I will definitely check this out later.

1 Like

Update 1.0.2

  • Prettied up the code, and dropped unnecessary lines.
  • Dropped support for “wallPost” and “shout”, they’ll be reimplemented later.
  • Fixed a bug that wouldn’t allow you to create multiple client objects.

Added new endpoints:

  • group.payout | Pays the specified user a one-time payout from group funds.
  • group.getSales | Gets the specified group’s past sales.
  • group.getRobuxAmount | Gets the group’s current number of Robux stored in funds.
  • user.getTransactionHistory | Gets the authorized user’s past sales / purchases.
  • user.getRobuxAmount | Gets the authorized user’s number of Robux.
1 Like

Damn, Roblox API Wrappers used to only be about Python and Node.JS. Now we got C#, C++, Java, Kotlin. And now Lua.

2 Likes

In fact, Lua is based off of JavaScript, meaning that you can learn it in about 3-5 hours if you know intermediatte lua.

noblox.js has wayyyyyy more functions (including asset functions), and it is used in JavaScript. I suggest you use noblox.js.

2 Likes

I’m still working on adding functions. It’s not worth adding asset functions if nobody uses it as of now. If it starts to grow enough, asset functions, and tons more will 100% be added.

1 Like

By not adding functions for assets or others, no one will use it. You need to give (more functions) to get (more users)

1 Like

Lua is based off of JavaScript

image

image

8 Likes

I didn’t mean it like that, I meant that they are super similar.

2 Likes

Lua and JavaScript aren’t that similar really, the syntax and features are pretty different. They’re both interpreted languages and JavaScript has prototypes while Lua has metatables (basically prototypes) but, other than that, not that similar.

In what way are you thinking they are?

1 Like

They have most of the same functions, such as require. When I learned it, I found it pretty cool at how similiar they were.

1 Like

I mean, yeah, they kind of have similar functions. However, if you take literally any method in Lua, chances are most other modern languages will have it as well. By that logic all languages are similar to Lua. JavaScript has wayyyy more functions and features than Lua.

You’ll find it easier to learn any language (not just JavaScript) after learning Lua because you already know basic programming principles that can be applied to most languages. From then on, its just about learning the syntax and certain new features.

2 Likes

I think what he is talking about is how Lua code and JS code look alike. For instance:
local cheese = (path)

var cheese = require(path)

1 Like

It’s actually the opposite - JavaScript was influenced by Lua and some other languages.
image

3 Likes