With RbxRefresh, you can use external editors (Like Visual Studio Code, Sublime Text 3 or Atom) for ROBLOX development. RbxRefresh syncs your changes back into studio every time you save your files locally.
npm install rbxrefresh -g
rbxrefresh SOURCE_DIRECTORY
- Enable
game.HttpService.HttpEnabled
- Install and enable RbxRefresh Studio Plugin
- Make changes and save.
Your source folder should mirror the roblox explorer structure where 'src' represents game. i.e.
ProjectFolder
src
ReplicatedStorage
Classes
Module.ModuleScript.lua
ServerScriptService
Server.Script.lua
StarterPlayer
StarterPlayerScripts
Client.LocalScript.lua
You can integrate RbxRefresh into your project by creating a .vscode
folder inside your project directory.
Inside of your .vscode
folder create a file called tasks.json
Here's the source I use for using RbxRefresh as task
{
"version": "2.0.0",
"tasks": [
{
"taskName": "RbxRefresh",
"command": "rbxrefresh",
"args": ["${workspaceRoot}"],
"type": "shell",
"problemMatcher": [],
"group": {
"kind": "build",
"isDefault": true
}
}
]
}
After adding that, just hit ctrl+shift+B on Windows or cmd+shift+B on OSX to run RbxRefresh. Click inside the terminal pane and do Ctrl+C to cancel.
An easy way to use Sublime Text 3 with RbxRefresh is by creating a build system.
You can do this using the following steps:
- Tools > Build System > New Build System...
- Paste the following into the new file
{
"cmd": ["rbxrefresh", "$folder"],
"shell": true
}
- Save it as
RbxRefresh.sublime-build
- Tools > Build System > RbxRefresh
After creating the build system you can use Ctrl+B
on Windows or Cmd+B
on MacOS to start RbxRefresh instantly.
RbxRefresh will be run on your top most project folder in the side bar.
To add a project folder to Sublime, just drag it onto the window.