create_project_script
Saves Lua code as a named file in a project, choosing sync or drafts folder, for Roblox BedWars Creative scripting.
Instructions
Save supplied Lua code in a named MCP-managed project under scripts/projects/. Inputs: project_name (required string, a project name rather than a directory path); file_name (required string, relative .lua path inside the chosen section); code (required string, Lua source); sync (optional boolean, default true: choose sync/; false: choose drafts/). Effects: creates parent folders and atomically replaces the file without a backup; does not prepare project metadata, validate, or directly upload. Returns: project_name, project-relative file_name, absolute path, sync selection, and bytes.
Context: Choose for a project identified by name. Use create_project first if its brief, manifest, and starter main.lua are needed. sync is a folder selector, not an upload action. For an arbitrary directory use create_directory_script. To upload this layout, connect the project directory with glob_pattern='sync//*.lua'; the usual scripts//*.lua glob does not select sync/. An existing matching watcher may upload the saved file.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"project_name": "<project_name>",
"file_name": "<file_name>",
"code": "<code>"
},
"name": "create_project_script"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| code | Yes | ||
| sync | No | ||
| file_name | Yes | ||
| project_name | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||