TL;DR install node, install noblox.js and write some code
It’s easy to start using noblox.js, install node like the link in @ReduxGB’s post.
Once you have node installed, create a new directory using the mkdir
command, and name it whatever you wish.
Now, run npm init
and fill out the inputs as needed, you can hit enter for all the boxes(most of the time).
You’ll now have a file called package.json
inside your project directory. Opening it using something like nano
it should look something like this:
{
"name": "tut",
"version": "1.0.0",
"description": "Tutorial for the devfourm.",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "BashGuy10",
"license": "ISC"
}
Now since we have our node project initialized, we can install noblox.js and write some code!
I tend to just use npm i noblox.js
to install it, but you can use the snippets in @ReduxGB’s post if you wish.
After running the command, package.json
should have this bit added to the bottom.
"dependencies": {
"noblox.js": "^4.7.3"
}
Now that we now noblox.js is installed, we can get into the programming.
We need to create our file that node will use, run touch index.js
, now check if index.js
exists by running dir
. You should also see additional files like node_modules
and package-lock.json
.
Once you’ve checked that index.js
exists, we can start editing the file, I use nano index.js
to edit it in my Raspberry Pi.
Writing the following code down, we should have followed Roblox’s user.
const rbx = require("noblox.js")
async function run() {
await rbx.setCookie("rblx security cookie here");
rbx.follow(1).catch(console.error) // catch any errors that may happen
}
run();
For more functions, visit noblox.js’s wiki for help.
Code created on the fly, LMK if there are any errors that stop the program from running.
DM me or reply to this post if you have any extra questions about noblox.js.