iron-stag-games / lync Goto Github PK
View Code? Open in Web Editor NEWLync is a file sync tool for Roblox.
License: GNU Lesser General Public License v2.1
Lync is a file sync tool for Roblox.
License: GNU Lesser General Public License v2.1
May also apply to meta files.
"$path": { "optional": "../node_modules" }
.model.json files are not being parsed correctly, and seemingly, they break live sync.
Saving the same .model.json file produces a series of odd logs, which may be a lead:
Terminal:
Mapping JsonModel 'tree/ReplicatedStorage/Lycan/Tes' -> [source\platform\shared\TestModel.model.json]
Mapping JsonModel 'tree/ReplicatedStorage/Lyc' -> [source\platform\shared\TestModel.model.json]
Mapping JsonModel 'tree/ReplicatedStora' -> [source\platform\shared\TestModel.model.json]
Studio:
'ReplicatedStora' is not a valid Service name
Stack Begin
Script 'user_Lync.rbxm.Plugin', Line 441 - function buildPath
Script 'user_Lync.rbxm.Plugin', Line 876
Stack End
To reproduce:
(Lune update required, 0.7.7 or higher)
node:internal/fs/utils:351
throw err;
^
Error: ENOENT: no such file or directory, open 'C:\Users\ian\AppData\Local\Roblox\undefined\InstalledPlugins\0\settings.json'
at Object.openSync (node:fs:602:3)
at Object.readFileSync (node:fs:470:35)
at Server.<anonymous> (C:\Users\ian\AppData\Local\Roblox\Lync\index.js:1026:33)
at Server.emit (node:events:514:28)
at parserOnIncoming (node:_http_server:1132:12)
at HTTPParser.parserOnHeadersComplete (node:_http_common:119:17) {
errno: -4058,
syscall: 'open',
code: 'ENOENT',
path: 'C:\\Users\\ian\\AppData\\Local\\Roblox\\undefined\\InstalledPlugins\\0\\settings.json'
}
To test this, simply setup a new project with a standard default.project.json with a packages folder defined:
"ServerScriptService": {
"Server": {
"$clearOnSync": true,
"$path": "src/server",
"lib": {
"$className": "Folder",
"$path": "./ServerPackages"
}
}
},
Install a few wally packages to that folder. Some examples you might want to use:
[server-dependencies]
Cmdr = "evaera/[email protected]"
ProfileService = "grilme99/[email protected]"
Sync to a baseplate and do one of the following:
lib
wally.toml
and run wally install
wally.toml
and run wally install
wally.toml
and run wally install
In the cases that involved changing installed libraries, none of the changes replicate if they occur while sync is active. Pausing the plugin, resuming the plugin, or restarting the Win_Sync.bat
script do not cause the changes to replicate. Studio has to be restarted.
Deleting lib
in Roblox Studio permanently removes it until Studio is restarted, even if the listed pause/resume/restart steps listed above for the previous test are attempted.
For instances that are assigned a $path
in the default.project.json file, upon modifying them, they seem to default to their file name, which causes them to duplicate, and sync to the wrong instance. (apologies if this sounds confusing, hopefully the reproduction steps clear things up)
To Reproduce:
$path
property{
"name": "Ballistic",
"tree": {
"ReplicatedFirst": {
"$className": "ReplicatedFirst",
"ClientLoader": {
"$path": "source/ballistic/game.client.luau"
}
}
}
}
Mapping Instance 'tree/ReplicatedFirst/ClientLoader' -> [source\ballistic\game.client.luau]
Mapping Lua 'tree/ReplicatedFirst/ClientLoader' -> [source\ballistic\game.client.luau]
M [source\ballistic\game.client.luau]
Mapping Lua 'tree/ReplicatedFirst/game' -> [source\ballistic\game.client.luau]
source\ballistic\game.client.luau
will apply to ReplicatedFirst/game
, rather than the expected ReplicatedFirst/ClientLoader
Note: I have only tested this with luau files, although I assume the same issue would persist with other formats as well.
Yaml files are neat, but currently you can't define any roblox types or instance paths.
I propose a syntax that lets you embed some luau code into yaml:
myVec: @"Vector3.new(1, 2, 3)"
Anything inside @""
is synced as luau code.
To use the @
character itself, you should be able to do @@
- this wont count as embed syntax and instead will just result in a @
character.
As of Lune 0.7.0 there are a few API changes that break the Lune scripts generated to be used for offline builds.
Writing validation script . . .
Validating loadstrings . . .
Writing build script . . .
Building RBXL . . .
attempt to call a nil value
[Stack Begin]
Script 'game.rbxl', Line 84
[Stack End]
Additionally, I tried using a version before these changes were made (0.6.7), although it started producing different errors this time.
Writing validation script . . .
Validating loadstrings . . .
Writing build script . . .
Building RBXL . . .
[ERROR]
[Lync] - Set Property DevComputerMovementMode: callback error
stack traceback:
[C]: in ?
[string "game.rbxl"]:170: in ?
[C]: in function 'pcall'
[string "game.rbxl"]:62: in function 'lpcall'
[string "game.rbxl"]:166: in function 'setDetails'
[string "game.rbxl"]:383: in function 'buildPath'
[string "game.rbxl"]:420: in function 'buildAll'
[string "game.rbxl"]:428: in ?
caused by: error converting Lua string to userdata
[Stack Begin]
Script 'game.rbxl', Line 64 - function lpcall
Script 'game.rbxl', Line 166 - function setDetails
Script 'game.rbxl', Line 383 - function buildPath
Script 'game.rbxl', Line 420 - function buildAll
Script 'game.rbxl', Line 428
[Stack End]
Writing validation script . . .
Validating loadstrings . . .
Writing build script . . .
Building RBXL . . .
error converting Lua string to userdata (expected userdata of type lune_roblox::datatypes::types::enum_item::EnumItem)
[Stack Begin]
Script '[C]'
Script 'game.rbxl', Line 165
Script 'game.rbxl', Line 62 - function lpcall
Script 'game.rbxl', Line 161 - function setDetails
Script 'game.rbxl', Line 378 - function buildPath
Script 'game.rbxl', Line 415 - function buildAll
Script 'game.rbxl', Line 423
[Stack End]
default.project.json as requested
{
"name": "Ballistic",
"tree": {
"$className": "DataModel",
"ServerStorage": {
"$className": "ServerStorage",
"Lycan": {
"$path": "source/platform/server"
},
"Ballistic": {
"$path": "source/ballistic/server"
}
},
"ReplicatedStorage": {
"$className": "ReplicatedStorage",
"Lycan": {
"$path": "source/platform/shared",
"client": {
"$path": "source/platform/client"
},
"packages": {
"$path": "Packages"
}
},
"Ballistic": {
"$path": "source/ballistic/shared"
},
"Resources": {
"$path": "resources/resources.manifest.rbxm"
}
},
"ReplicatedFirst": {
"$className": "ReplicatedFirst",
"ClientLoader": {
"$path": "source/ballistic/game.client.luau"
}
},
"ServerScriptService": {
"$className": "ServerScriptService",
"ServerLoader": {
"$path": "source/ballistic/game.server.luau"
}
},
"StarterPlayer": {
"$className": "StarterPlayer",
"$properties": {
"CameraMode": "LockFirstPerson",
"DevComputerCameraMovementMode": "Classic",
"DevTouchCameraMovementMode": "Classic",
"LoadCharacterAppearance": false,
"UserEmotesEnabled": false,
"DevComputerMovementMode": "Scriptable",
"DevTouchMovementMode": "Scriptable"
}
},
"Players": {
"$className": "Players",
"$properties": {
"CharacterAutoLoads": false
}
},
"Workspace": {
"$className": "Workspace",
"$properties": {
"FilteringEnabled": true
}
},
"SoundService": {
"$className": "SoundService",
"$properties": {
"RespectFilteringEnabled": true
}
}
}
}
Whenever I create a new folder, it fails to sync in properly. When that happens, the only way to get everything up again is to restart studio and start serving again
A [assets\server\animations\weapons]
Sync error: TypeError: Cannot read properties of undefined (reading 'toLowerCase')
at localPathIsInit (C:\Users\ian\AppData\Local\Roblox\Lync\index.js:105:45)
at FSWatcher.<anonymous> (C:\Users\ian\AppData\Local\Roblox\Lync\index.js:985:22)
at FSWatcher.emit (node:events:514:28)
at FSWatcher.emitWithAll (C:\Users\ian\AppData\Local\Roblox\Lync\node_modules\chokidar\index.js:541:32)
at FSWatcher._emit (C:\Users\ian\AppData\Local\Roblox\Lync\node_modules\chokidar\index.js:632:8)
at NodeFsHandler._handleDir (C:\Users\ian\AppData\Local\Roblox\Lync\node_modules\chokidar\lib\nodefs-handler.js:551:53)
at NodeFsHandler._addToNodeFs (C:\Users\ian\AppData\Local\Roblox\Lync\node_modules\chokidar\lib\nodefs-handler.js:617:27)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
Required for #43
npm install
I'd like meta and project files to support yaml too. Json is too verbose and strict.
Example json meta file
{
"properties": {
"RunContext": "Server"
}
}
Example yaml meta file:
properties:
RunContext: Server
The lua file for the plugin was moved elsewhere although the old directory is still being referenced in the source code.
In line 615:
let pluginSource = fs.readFileSync(path.resolve(__dirname, 'plugin.source.lua'), { encoding: 'utf8' })
Changing it to RobloxPluginSource/Plugin.lua
fixes the issue.
The error in case you still need it:
node:fs:601
handleErrorFromBinding(ctx);
^
Error: ENOENT: no such file or directory, open 'C:\Users\canis\AppData\Local\Roblox\Lync\plugin.source.lua'
at Object.openSync (node:fs:601:3)
at Object.readFileSync (node:fs:469:35)
at C:\Users\canis\AppData\Local\Roblox\Lync\index.js:615:25
at Object.<anonymous> (C:\Users\canis\AppData\Local\Roblox\Lync\index.js:955:3)
at Module._compile (node:internal/modules/cjs/loader:1254:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1308:10)
at Module.load (node:internal/modules/cjs/loader:1117:32)
at Module._load (node:internal/modules/cjs/loader:958:12)
at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:81:12)
at node:internal/main/run_main_module:23:47 {
errno: -4058,
syscall: 'open',
code: 'ENOENT',
path: 'C:\\Users\\canis\\AppData\\Local\\Roblox\\Lync\\plugin.source.lua'
}
For Offline Builds and Lync Wire.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.