How to Export Scripts in a Roblox Place

You should use rbxlx-to-rojo to accomplish this instead! The method and tool outlined on this page is not actively maintained and has a few issues that I won’t be fixing anytime soon. It’s only here for archival purposes. Welcome to the future.

Turn your game’s hierarchy of scripts into folders and Lua files

I made a command-line tool in Java that exports all scripts in an XML Roblox place file. It outputs every script in the place as files in a directory structure that mirrors the game hierarchy. Script objects are exported as .lua, ModuleScripts export as .module.lua, and LocalScripts export as .local.lua. Duplicate names are handled with numbers, ie [1], [2], and so on.

How to Export Scripts in a Roblox Place

  1. First, you will need the following:
  2. Make sure ScriptExport.jar and your rbxlx file are within the same directory. Then, via the command line, run the jar file using Java (assuming you have Java in your PATH environment variable on Windows):
    java -jar ScriptExport.jar place.rbxlx
    Be sure to change place.rbxlx to your place’s file name.


  3. Wait for the process to complete. It should take a short while for large projects. Your output will be in a directory called place.rbxlx_export, or something similar to your file name.

Warning: This tool uses Java’s XML parsers, and it is possible to break these if any script in your game has a non-XML character. For example, one of Roblox’s core scripts used in the default chat system has a strange character on CurveUtil.lua’s line 55. Be sure to delete any invalid XML characters, as Roblox will export these without properly escaping them.