sentanos / roblox-js

!!!THIS PROJECT IS NO LONGER MAINTAINED!!! Execute ROBLOX website actions in node.js
MIT License
45 stars 45 forks source link

getFeed #40

Closed Conmmander closed 7 years ago

Conmmander commented 7 years ago

I finally got a way to grab the players status on roblox!

// Includes var http = require('./http.js').func; var parser = require('cheerio');

// Args exports.required = ['userId'];

// Define exports.func = function (args) { return new Promise(function (resolve, reject) { http({ url: 'https://www.roblox.com/users/' + args.userId + '/profile' }) .then(function (body) { var matches = body.match(/data-statustext="?(.*?)"? data-edit/); resolve((matches && matches[1]) ? matches[1] : false); }) }) }

I grabbed the code from the dev branch, so it is most likely more compatible with the stuff inside of there.

sentanos commented 7 years ago

Whoa! Make a pull request by forking the dev branch and then making a pull request there.