Project
Projects describe how the instance tree should look like and how files should be processed along the way!
Project File
Argon projects are JSON files that have the .project.json
extension. They have the following fields:
Field | Default | Description |
---|---|---|
name * | default | The name of the project, displayed by Argon |
tree * | Required | An Instance Description describing the root instance of the project |
host | localhost | The host name that Argon server should be running on |
port | 8000 | The port number that Argon server should be running on |
gameId * | null | Limit Argon clients to only sync with this project when the game ID matches |
placeIds * | [] | Limit Argon clients to only sync with this project when one of the place IDs matches |
ignoreGlobs | [] | Exclude files that match any of these globs from processing and syncing |
syncRules | [] | Custom set of user-defined Sync Rules that define how files should be processed |
syncback | null | Syncback Settings that control how instances are synced back to the file system |
legacyScripts | true | Use the legacy script run context |
* These fields can be hot-reloaded so you don't need to restart the server to apply changes
Rojo Compatibility
Argon is 100% compatible with Rojo projects with the exception of the placeId
field which should be moved to the placeIds
array. Although some field names differ from Rojo ones, they work the same way and are interchangeable:
serveAddress
==host
servePort
==port
servePlaceIds
==placeIds
globIgnorePaths
==ignoreGlobs
emitLegacyScripts
==legacyScripts
Instance Description
Instance Descriptions correspond to the actual Roblox Instances in the project.
Field | Description |
---|---|
$className | The ClassName of the Instance being described |
$path | The path on the filesystem that should be the source of this instance |
$properties | Properties to apply to the instance |
$keepUnknowns | Whether instances that Argon doesn't know about should be deleted |
All other fields in an Instance Description are turned into instances whose name is the key.
Note that you can't set both $className
and $path
at the same time!
Sync Rule
Sync Rule allows you to define how specific file should be interpreted and how its name should be mapped to the instance name.
Field | Description |
---|---|
type | The type of file this rule applies to, valid options are: Project, InstanceData, ServerScript, ClientScript, ModuleScript, StringValue, LocalizationTable, JsonModule, TomlModule, JsonModel, RbxmModel, RbxmxModel |
pattern | A glob pattern that matches the file path |
childPattern | A glob pattern that matches folder-contained file path |
exclude | A list of glob patterns that exclude the file path from this rule |
suffix | A suffix to stripe from the file path to get the instance name |
Syncback Settings
Syncback Settings allow you to control which instances and properties should be synced back to the file system.
Setting | Description |
---|---|
ignoreGlobs | Exclude files that match any of these globs from processing changes |
ignoreNames | Exclude instances with these names from processing changes |
ignoreClasses | Exclude instances with these classes from processing changes |
ignoreProperties | Exclude these properties from being saved to the file system |
Example Projects
Example project of a plugin or model:
{
"name": "Plugin",
"ignoreGlobs": ["**/*.spec.lua"],
"tree": {
"$path": "src",
"manifest": {
"$path": "wally.toml"
}
}
}
Example project of a game:
{
"name": "Game",
"port:": 8080,
"gameId": "1234567890",
"tree": {
"$className": "DataModel",
"ReplicatedStorage": {
"$path": "src/Shared",
"Config": {
"$className": "Configuration",
"$keepUnknowns": true,
"StartPos": {
"$className": "Vector3Value",
"$properties": {
"Value": [0, 0, 0]
}
}
}
},
"ServerScriptService": {
"$path": "src/Server"
},
"StarterPlayer": {
"$properties": {
"CharacterWalkSpeed": 24
},
"StarterPlayerScripts": {
"$path": "src/Client"
}
}
}
}
This page is based on Rojo's Project Format as Argon has very similar project structure.