Filesystem
Workspace files, directories, assets, dialogs and partial exports.
All paths in this group stay inside Acedia's profile-owned workspace. Read and write calls handle byte strings; dialogs select workspace items in game.
Write and read a file
makefolder("examples")
writefile("examples/note.txt", "first line\n")
appendfile("examples/note.txt", "second line\n")
print(readfile("examples/note.txt"))makefolder creates missing parents and succeeds if the folder already exists. listfiles returns direct children as workspace-relative paths.
Path rules
- Paths cannot escape the workspace using
.., an absolute path, a device path, or alternate-stream syntax. listfiles(".")andlistfiles("")select the workspace root.loadfilerejects..anywhere in the supplied name and limits input to 64 MiB.delfolderremoves an entire directory tree, but refuses to delete the workspace root.
Blocked file types: Writes to potentially executable or container files are blocked. These include:
.exe,.com,.scr,.pif,.cpl,.msc,.bat,.cmd,.ps1,.psd1,.vbs,.vbe,.js,.jse,.wsf,.wsh,.hta,.scf,.lnk,.zip,.rar,.7z,.cab,.iso,.img,.xml,.msi,.msp,.reg,.inf, and.url.
File pickers such as openfiledialog return nil on cancellation. getcustomasset returns an asset URI, not raw image bytes. For saved Instance trees, saveinstance writes a partial .rbxmx export; see partial exports.
Functions
| Function | Purpose |
|---|---|
| readfile | Reads a workspace file as a binary-safe string. |
| isfile | Checks whether a workspace path is a file. |
| isfolder | Checks whether a workspace path is a directory. |
| makefolder | Creates a workspace directory. |
| delfile | Deletes a workspace file. |
| renamefile | Renames or moves a workspace file. |
| getfilesize | Returns the size of a workspace file in bytes. |
| delfolder | Deletes a workspace folder. |
| listfiles | Lists immediate entries beneath a workspace directory. |
| getcustomasset | Copies a workspace asset into the engine content path and returns its asset URI. |
| writefile | Creates or replaces a workspace file. |
| appendfile | Appends bytes to a workspace file. |
| loadfile | Compiles a workspace file without executing it. |
| dofile | Compiles and executes a workspace Luau file. |
| saveinstance | Writes a partial Instance-tree export to an RBXMX file. |
| openfiledialog | Opens an in-game workspace picker for one file. |
| openfilesdialog | Opens an in-game workspace picker for multiple files. |
| openfolderdialog | Opens an in-game workspace picker for a folder. |
| savefiledialog | Selects a workspace folder and prepares a file with a suggested name. |
