[add] 設定env
This commit is contained in:
parent
acd1cb7337
commit
84bba89e7e
3
.vscode/launch.json
vendored
3
.vscode/launch.json
vendored
@ -11,6 +11,9 @@
|
|||||||
"runtimeExecutable": "${workspaceFolder}/node_modules/.bin/electron.cmd"
|
"runtimeExecutable": "${workspaceFolder}/node_modules/.bin/electron.cmd"
|
||||||
},
|
},
|
||||||
"args": ["."],
|
"args": ["."],
|
||||||
|
"env": {
|
||||||
|
"NODE_ENV": "dev"
|
||||||
|
},
|
||||||
"outputCapture": "std",
|
"outputCapture": "std",
|
||||||
"sourceMaps": true,
|
"sourceMaps": true,
|
||||||
"restart": true
|
"restart": true
|
||||||
|
4
.vscode/tasks.json
vendored
4
.vscode/tasks.json
vendored
@ -6,14 +6,14 @@
|
|||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "npm",
|
"command": "npm",
|
||||||
"args": ["run", "build"],
|
"args": ["run", "build"],
|
||||||
"problemMatcher": []
|
"problemMatcher": [],
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"label": "npm: start",
|
"label": "npm: start",
|
||||||
"type": "shell",
|
"type": "shell",
|
||||||
"command": "npm",
|
"command": "npm",
|
||||||
"args": ["start"],
|
"args": ["start"],
|
||||||
"problemMatcher": []
|
"problemMatcher": [],
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
504
package-lock.json
generated
504
package-lock.json
generated
@ -12,7 +12,6 @@
|
|||||||
"dayjs": "^1.11.13",
|
"dayjs": "^1.11.13",
|
||||||
"dotenv": "^16.4.5",
|
"dotenv": "^16.4.5",
|
||||||
"module-alias": "^2.2.3",
|
"module-alias": "^2.2.3",
|
||||||
"tsrpc": "^3.4.16",
|
|
||||||
"ws": "^8.18.0"
|
"ws": "^8.18.0"
|
||||||
},
|
},
|
||||||
"bin": {
|
"bin": {
|
||||||
@ -22,6 +21,7 @@
|
|||||||
"@types/node": "^22.5.0",
|
"@types/node": "^22.5.0",
|
||||||
"@types/ws": "^8.5.12",
|
"@types/ws": "^8.5.12",
|
||||||
"copyfiles": "^2.4.1",
|
"copyfiles": "^2.4.1",
|
||||||
|
"cross-env": "^7.0.3",
|
||||||
"electron": "^32.0.1",
|
"electron": "^32.0.1",
|
||||||
"electron-builder": "^24.7.0",
|
"electron-builder": "^24.7.0",
|
||||||
"electron-packager": "^17.1.2",
|
"electron-packager": "^17.1.2",
|
||||||
@ -98,6 +98,29 @@
|
|||||||
"global-agent": "^3.0.0"
|
"global-agent": "^3.0.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"node_modules/@electron/get/node_modules/fs-extra": {
|
||||||
|
"version": "8.1.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-8.1.0.tgz",
|
||||||
|
"integrity": "sha512-yhlQgA6mnOJUKOsRUFsgJdQCvkKhcz8tlZG5HBQfReYZy46OwLcY+Zia0mtdHsOo9y/hP+CxMN0TU9QxoOtG4g==",
|
||||||
|
"dev": true,
|
||||||
|
"dependencies": {
|
||||||
|
"graceful-fs": "^4.2.0",
|
||||||
|
"jsonfile": "^4.0.0",
|
||||||
|
"universalify": "^0.1.0"
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"node": ">=6 <7 || >=8"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"node_modules/@electron/get/node_modules/jsonfile": {
|
||||||
|
"version": "4.0.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-4.0.0.tgz",
|
||||||
|
"integrity": "sha512-m6F1R3z8jjlf2imQHS2Qez5sjKWQzbuuhuJ/FKYFRZvPE3PuHcSMVZzfsLhGVOkfd20obL5SWEBew5ShlquNxg==",
|
||||||
|
"dev": true,
|
||||||
|
"optionalDependencies": {
|
||||||
|
"graceful-fs": "^4.1.6"
|
||||||
|
}
|
||||||
|
},
|
||||||
"node_modules/@electron/get/node_modules/semver": {
|
"node_modules/@electron/get/node_modules/semver": {
|
||||||
"version": "6.3.1",
|
"version": "6.3.1",
|
||||||
"resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz",
|
"resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz",
|
||||||
@ -107,6 +130,15 @@
|
|||||||
"semver": "bin/semver.js"
|
"semver": "bin/semver.js"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"node_modules/@electron/get/node_modules/universalify": {
|
||||||
|
"version": "0.1.2",
|
||||||
|
"resolved": "https://registry.npmjs.org/universalify/-/universalify-0.1.2.tgz",
|
||||||
|
"integrity": "sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==",
|
||||||
|
"dev": true,
|
||||||
|
"engines": {
|
||||||
|
"node": ">= 4.0.0"
|
||||||
|
}
|
||||||
|
},
|
||||||
"node_modules/@electron/notarize": {
|
"node_modules/@electron/notarize": {
|
||||||
"version": "1.2.4",
|
"version": "1.2.4",
|
||||||
"resolved": "https://registry.npmjs.org/@electron/notarize/-/notarize-1.2.4.tgz",
|
"resolved": "https://registry.npmjs.org/@electron/notarize/-/notarize-1.2.4.tgz",
|
||||||
@ -135,27 +167,6 @@
|
|||||||
"node": ">=10"
|
"node": ">=10"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@electron/notarize/node_modules/jsonfile": {
|
|
||||||
"version": "6.1.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz",
|
|
||||||
"integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==",
|
|
||||||
"dev": true,
|
|
||||||
"dependencies": {
|
|
||||||
"universalify": "^2.0.0"
|
|
||||||
},
|
|
||||||
"optionalDependencies": {
|
|
||||||
"graceful-fs": "^4.1.6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@electron/notarize/node_modules/universalify": {
|
|
||||||
"version": "2.0.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz",
|
|
||||||
"integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==",
|
|
||||||
"dev": true,
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 10.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@electron/osx-sign": {
|
"node_modules/@electron/osx-sign": {
|
||||||
"version": "1.3.1",
|
"version": "1.3.1",
|
||||||
"resolved": "https://registry.npmjs.org/@electron/osx-sign/-/osx-sign-1.3.1.tgz",
|
"resolved": "https://registry.npmjs.org/@electron/osx-sign/-/osx-sign-1.3.1.tgz",
|
||||||
@ -191,27 +202,6 @@
|
|||||||
"node": ">=12"
|
"node": ">=12"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@electron/osx-sign/node_modules/jsonfile": {
|
|
||||||
"version": "6.1.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz",
|
|
||||||
"integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==",
|
|
||||||
"dev": true,
|
|
||||||
"dependencies": {
|
|
||||||
"universalify": "^2.0.0"
|
|
||||||
},
|
|
||||||
"optionalDependencies": {
|
|
||||||
"graceful-fs": "^4.1.6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@electron/osx-sign/node_modules/universalify": {
|
|
||||||
"version": "2.0.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz",
|
|
||||||
"integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==",
|
|
||||||
"dev": true,
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 10.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@electron/universal": {
|
"node_modules/@electron/universal": {
|
||||||
"version": "1.5.1",
|
"version": "1.5.1",
|
||||||
"resolved": "https://registry.npmjs.org/@electron/universal/-/universal-1.5.1.tgz",
|
"resolved": "https://registry.npmjs.org/@electron/universal/-/universal-1.5.1.tgz",
|
||||||
@ -245,27 +235,6 @@
|
|||||||
"node": ">=10"
|
"node": ">=10"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@electron/universal/node_modules/jsonfile": {
|
|
||||||
"version": "6.1.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz",
|
|
||||||
"integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==",
|
|
||||||
"dev": true,
|
|
||||||
"dependencies": {
|
|
||||||
"universalify": "^2.0.0"
|
|
||||||
},
|
|
||||||
"optionalDependencies": {
|
|
||||||
"graceful-fs": "^4.1.6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@electron/universal/node_modules/universalify": {
|
|
||||||
"version": "2.0.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz",
|
|
||||||
"integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==",
|
|
||||||
"dev": true,
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 10.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@isaacs/cliui": {
|
"node_modules/@isaacs/cliui": {
|
||||||
"version": "8.0.2",
|
"version": "8.0.2",
|
||||||
"resolved": "https://registry.npmjs.org/@isaacs/cliui/-/cliui-8.0.2.tgz",
|
"resolved": "https://registry.npmjs.org/@isaacs/cliui/-/cliui-8.0.2.tgz",
|
||||||
@ -439,27 +408,6 @@
|
|||||||
"node": ">=10"
|
"node": ">=10"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@malept/flatpak-bundler/node_modules/jsonfile": {
|
|
||||||
"version": "6.1.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz",
|
|
||||||
"integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==",
|
|
||||||
"dev": true,
|
|
||||||
"dependencies": {
|
|
||||||
"universalify": "^2.0.0"
|
|
||||||
},
|
|
||||||
"optionalDependencies": {
|
|
||||||
"graceful-fs": "^4.1.6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@malept/flatpak-bundler/node_modules/universalify": {
|
|
||||||
"version": "2.0.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz",
|
|
||||||
"integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==",
|
|
||||||
"dev": true,
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 10.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@pkgjs/parseargs": {
|
"node_modules/@pkgjs/parseargs": {
|
||||||
"version": "0.11.0",
|
"version": "0.11.0",
|
||||||
"resolved": "https://registry.npmjs.org/@pkgjs/parseargs/-/parseargs-0.11.0.tgz",
|
"resolved": "https://registry.npmjs.org/@pkgjs/parseargs/-/parseargs-0.11.0.tgz",
|
||||||
@ -582,6 +530,7 @@
|
|||||||
"version": "22.5.0",
|
"version": "22.5.0",
|
||||||
"resolved": "https://registry.npmjs.org/@types/node/-/node-22.5.0.tgz",
|
"resolved": "https://registry.npmjs.org/@types/node/-/node-22.5.0.tgz",
|
||||||
"integrity": "sha512-DkFrJOe+rfdHTqqMg0bSNlGlQ85hSoh2TPzZyhHsXnMtligRWpxUySiyw8FY14ITt24HVCiQPWxS3KO/QlGmWg==",
|
"integrity": "sha512-DkFrJOe+rfdHTqqMg0bSNlGlQ85hSoh2TPzZyhHsXnMtligRWpxUySiyw8FY14ITt24HVCiQPWxS3KO/QlGmWg==",
|
||||||
|
"dev": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"undici-types": "~6.19.2"
|
"undici-types": "~6.19.2"
|
||||||
}
|
}
|
||||||
@ -748,6 +697,7 @@
|
|||||||
"version": "4.3.0",
|
"version": "4.3.0",
|
||||||
"resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz",
|
"resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz",
|
||||||
"integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==",
|
"integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==",
|
||||||
|
"dev": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"color-convert": "^2.0.1"
|
"color-convert": "^2.0.1"
|
||||||
},
|
},
|
||||||
@ -928,18 +878,6 @@
|
|||||||
"url": "https://github.com/sponsors/gjtorikian/"
|
"url": "https://github.com/sponsors/gjtorikian/"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/app-builder-lib/node_modules/jsonfile": {
|
|
||||||
"version": "6.1.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz",
|
|
||||||
"integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==",
|
|
||||||
"dev": true,
|
|
||||||
"dependencies": {
|
|
||||||
"universalify": "^2.0.0"
|
|
||||||
},
|
|
||||||
"optionalDependencies": {
|
|
||||||
"graceful-fs": "^4.1.6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/app-builder-lib/node_modules/minimatch": {
|
"node_modules/app-builder-lib/node_modules/minimatch": {
|
||||||
"version": "5.1.6",
|
"version": "5.1.6",
|
||||||
"resolved": "https://registry.npmjs.org/minimatch/-/minimatch-5.1.6.tgz",
|
"resolved": "https://registry.npmjs.org/minimatch/-/minimatch-5.1.6.tgz",
|
||||||
@ -952,15 +890,6 @@
|
|||||||
"node": ">=10"
|
"node": ">=10"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/app-builder-lib/node_modules/universalify": {
|
|
||||||
"version": "2.0.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz",
|
|
||||||
"integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==",
|
|
||||||
"dev": true,
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 10.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/archiver": {
|
"node_modules/archiver": {
|
||||||
"version": "5.3.2",
|
"version": "5.3.2",
|
||||||
"resolved": "https://registry.npmjs.org/archiver/-/archiver-5.3.2.tgz",
|
"resolved": "https://registry.npmjs.org/archiver/-/archiver-5.3.2.tgz",
|
||||||
@ -1390,27 +1319,6 @@
|
|||||||
"node": ">=12"
|
"node": ">=12"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/builder-util/node_modules/jsonfile": {
|
|
||||||
"version": "6.1.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz",
|
|
||||||
"integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==",
|
|
||||||
"dev": true,
|
|
||||||
"dependencies": {
|
|
||||||
"universalify": "^2.0.0"
|
|
||||||
},
|
|
||||||
"optionalDependencies": {
|
|
||||||
"graceful-fs": "^4.1.6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/builder-util/node_modules/universalify": {
|
|
||||||
"version": "2.0.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz",
|
|
||||||
"integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==",
|
|
||||||
"dev": true,
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 10.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/cacheable-lookup": {
|
"node_modules/cacheable-lookup": {
|
||||||
"version": "5.0.4",
|
"version": "5.0.4",
|
||||||
"resolved": "https://registry.npmjs.org/cacheable-lookup/-/cacheable-lookup-5.0.4.tgz",
|
"resolved": "https://registry.npmjs.org/cacheable-lookup/-/cacheable-lookup-5.0.4.tgz",
|
||||||
@ -1442,6 +1350,7 @@
|
|||||||
"version": "4.1.2",
|
"version": "4.1.2",
|
||||||
"resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz",
|
"resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz",
|
||||||
"integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==",
|
"integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==",
|
||||||
|
"dev": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"ansi-styles": "^4.1.0",
|
"ansi-styles": "^4.1.0",
|
||||||
"supports-color": "^7.1.0"
|
"supports-color": "^7.1.0"
|
||||||
@ -1457,6 +1366,7 @@
|
|||||||
"version": "4.0.0",
|
"version": "4.0.0",
|
||||||
"resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz",
|
"resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz",
|
||||||
"integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==",
|
"integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==",
|
||||||
|
"dev": true,
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=8"
|
"node": ">=8"
|
||||||
}
|
}
|
||||||
@ -1465,6 +1375,7 @@
|
|||||||
"version": "7.2.0",
|
"version": "7.2.0",
|
||||||
"resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz",
|
"resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz",
|
||||||
"integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==",
|
"integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==",
|
||||||
|
"dev": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"has-flag": "^4.0.0"
|
"has-flag": "^4.0.0"
|
||||||
},
|
},
|
||||||
@ -1618,6 +1529,7 @@
|
|||||||
"version": "2.0.1",
|
"version": "2.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz",
|
"resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz",
|
||||||
"integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==",
|
"integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==",
|
||||||
|
"dev": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"color-name": "~1.1.4"
|
"color-name": "~1.1.4"
|
||||||
},
|
},
|
||||||
@ -1628,7 +1540,8 @@
|
|||||||
"node_modules/color-name": {
|
"node_modules/color-name": {
|
||||||
"version": "1.1.4",
|
"version": "1.1.4",
|
||||||
"resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz",
|
"resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz",
|
||||||
"integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA=="
|
"integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==",
|
||||||
|
"dev": true
|
||||||
},
|
},
|
||||||
"node_modules/combined-stream": {
|
"node_modules/combined-stream": {
|
||||||
"version": "1.0.8",
|
"version": "1.0.8",
|
||||||
@ -1911,6 +1824,24 @@
|
|||||||
"integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==",
|
"integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==",
|
||||||
"dev": true
|
"dev": true
|
||||||
},
|
},
|
||||||
|
"node_modules/cross-env": {
|
||||||
|
"version": "7.0.3",
|
||||||
|
"resolved": "https://registry.npmjs.org/cross-env/-/cross-env-7.0.3.tgz",
|
||||||
|
"integrity": "sha512-+/HKd6EgcQCJGh2PSjZuUitQBQynKor4wrFbRg4DtAgS1aWO+gU52xpH7M9ScGgXSYmAVS9bIJ8EzuaGw0oNAw==",
|
||||||
|
"dev": true,
|
||||||
|
"dependencies": {
|
||||||
|
"cross-spawn": "^7.0.1"
|
||||||
|
},
|
||||||
|
"bin": {
|
||||||
|
"cross-env": "src/bin/cross-env.js",
|
||||||
|
"cross-env-shell": "src/bin/cross-env-shell.js"
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"node": ">=10.14",
|
||||||
|
"npm": ">=6",
|
||||||
|
"yarn": ">=1"
|
||||||
|
}
|
||||||
|
},
|
||||||
"node_modules/cross-spawn": {
|
"node_modules/cross-spawn": {
|
||||||
"version": "7.0.3",
|
"version": "7.0.3",
|
||||||
"resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz",
|
"resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz",
|
||||||
@ -2121,27 +2052,6 @@
|
|||||||
"node": ">=12"
|
"node": ">=12"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/dmg-builder/node_modules/jsonfile": {
|
|
||||||
"version": "6.1.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz",
|
|
||||||
"integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==",
|
|
||||||
"dev": true,
|
|
||||||
"dependencies": {
|
|
||||||
"universalify": "^2.0.0"
|
|
||||||
},
|
|
||||||
"optionalDependencies": {
|
|
||||||
"graceful-fs": "^4.1.6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/dmg-builder/node_modules/universalify": {
|
|
||||||
"version": "2.0.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz",
|
|
||||||
"integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==",
|
|
||||||
"dev": true,
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 10.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/dmg-license": {
|
"node_modules/dmg-license": {
|
||||||
"version": "1.0.11",
|
"version": "1.0.11",
|
||||||
"resolved": "https://registry.npmjs.org/dmg-license/-/dmg-license-1.0.11.tgz",
|
"resolved": "https://registry.npmjs.org/dmg-license/-/dmg-license-1.0.11.tgz",
|
||||||
@ -2324,29 +2234,6 @@
|
|||||||
"node": ">=12"
|
"node": ">=12"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/electron-builder-squirrel-windows/node_modules/jsonfile": {
|
|
||||||
"version": "6.1.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz",
|
|
||||||
"integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==",
|
|
||||||
"dev": true,
|
|
||||||
"peer": true,
|
|
||||||
"dependencies": {
|
|
||||||
"universalify": "^2.0.0"
|
|
||||||
},
|
|
||||||
"optionalDependencies": {
|
|
||||||
"graceful-fs": "^4.1.6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/electron-builder-squirrel-windows/node_modules/universalify": {
|
|
||||||
"version": "2.0.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz",
|
|
||||||
"integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==",
|
|
||||||
"dev": true,
|
|
||||||
"peer": true,
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 10.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/electron-builder/node_modules/cliui": {
|
"node_modules/electron-builder/node_modules/cliui": {
|
||||||
"version": "8.0.1",
|
"version": "8.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz",
|
"resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz",
|
||||||
@ -2375,27 +2262,6 @@
|
|||||||
"node": ">=12"
|
"node": ">=12"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/electron-builder/node_modules/jsonfile": {
|
|
||||||
"version": "6.1.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz",
|
|
||||||
"integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==",
|
|
||||||
"dev": true,
|
|
||||||
"dependencies": {
|
|
||||||
"universalify": "^2.0.0"
|
|
||||||
},
|
|
||||||
"optionalDependencies": {
|
|
||||||
"graceful-fs": "^4.1.6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/electron-builder/node_modules/universalify": {
|
|
||||||
"version": "2.0.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz",
|
|
||||||
"integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==",
|
|
||||||
"dev": true,
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 10.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/electron-builder/node_modules/yargs": {
|
"node_modules/electron-builder/node_modules/yargs": {
|
||||||
"version": "17.7.2",
|
"version": "17.7.2",
|
||||||
"resolved": "https://registry.npmjs.org/yargs/-/yargs-17.7.2.tgz",
|
"resolved": "https://registry.npmjs.org/yargs/-/yargs-17.7.2.tgz",
|
||||||
@ -2451,41 +2317,6 @@
|
|||||||
"url": "https://github.com/electron/electron-packager?sponsor=1"
|
"url": "https://github.com/electron/electron-packager?sponsor=1"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/electron-packager/node_modules/fs-extra": {
|
|
||||||
"version": "11.2.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-11.2.0.tgz",
|
|
||||||
"integrity": "sha512-PmDi3uwK5nFuXh7XDTlVnS17xJS7vW36is2+w3xcv8SVxiB4NyATf4ctkVY5bkSjX0Y4nbvZCq1/EjtEyr9ktw==",
|
|
||||||
"dev": true,
|
|
||||||
"dependencies": {
|
|
||||||
"graceful-fs": "^4.2.0",
|
|
||||||
"jsonfile": "^6.0.1",
|
|
||||||
"universalify": "^2.0.0"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=14.14"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/electron-packager/node_modules/jsonfile": {
|
|
||||||
"version": "6.1.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz",
|
|
||||||
"integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==",
|
|
||||||
"dev": true,
|
|
||||||
"dependencies": {
|
|
||||||
"universalify": "^2.0.0"
|
|
||||||
},
|
|
||||||
"optionalDependencies": {
|
|
||||||
"graceful-fs": "^4.1.6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/electron-packager/node_modules/universalify": {
|
|
||||||
"version": "2.0.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz",
|
|
||||||
"integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==",
|
|
||||||
"dev": true,
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 10.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/electron-publish": {
|
"node_modules/electron-publish": {
|
||||||
"version": "24.13.1",
|
"version": "24.13.1",
|
||||||
"resolved": "https://registry.npmjs.org/electron-publish/-/electron-publish-24.13.1.tgz",
|
"resolved": "https://registry.npmjs.org/electron-publish/-/electron-publish-24.13.1.tgz",
|
||||||
@ -2515,27 +2346,6 @@
|
|||||||
"node": ">=12"
|
"node": ">=12"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/electron-publish/node_modules/jsonfile": {
|
|
||||||
"version": "6.1.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz",
|
|
||||||
"integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==",
|
|
||||||
"dev": true,
|
|
||||||
"dependencies": {
|
|
||||||
"universalify": "^2.0.0"
|
|
||||||
},
|
|
||||||
"optionalDependencies": {
|
|
||||||
"graceful-fs": "^4.1.6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/electron-publish/node_modules/universalify": {
|
|
||||||
"version": "2.0.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz",
|
|
||||||
"integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==",
|
|
||||||
"dev": true,
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 10.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/electron/node_modules/@types/node": {
|
"node_modules/electron/node_modules/@types/node": {
|
||||||
"version": "20.16.1",
|
"version": "20.16.1",
|
||||||
"resolved": "https://registry.npmjs.org/@types/node/-/node-20.16.1.tgz",
|
"resolved": "https://registry.npmjs.org/@types/node/-/node-20.16.1.tgz",
|
||||||
@ -2885,27 +2695,6 @@
|
|||||||
"node": ">=12"
|
"node": ">=12"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/flora-colossus/node_modules/jsonfile": {
|
|
||||||
"version": "6.1.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz",
|
|
||||||
"integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==",
|
|
||||||
"dev": true,
|
|
||||||
"dependencies": {
|
|
||||||
"universalify": "^2.0.0"
|
|
||||||
},
|
|
||||||
"optionalDependencies": {
|
|
||||||
"graceful-fs": "^4.1.6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/flora-colossus/node_modules/universalify": {
|
|
||||||
"version": "2.0.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz",
|
|
||||||
"integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==",
|
|
||||||
"dev": true,
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 10.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/foreground-child": {
|
"node_modules/foreground-child": {
|
||||||
"version": "3.3.0",
|
"version": "3.3.0",
|
||||||
"resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-3.3.0.tgz",
|
"resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-3.3.0.tgz",
|
||||||
@ -2944,17 +2733,17 @@
|
|||||||
"peer": true
|
"peer": true
|
||||||
},
|
},
|
||||||
"node_modules/fs-extra": {
|
"node_modules/fs-extra": {
|
||||||
"version": "8.1.0",
|
"version": "11.2.0",
|
||||||
"resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-8.1.0.tgz",
|
"resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-11.2.0.tgz",
|
||||||
"integrity": "sha512-yhlQgA6mnOJUKOsRUFsgJdQCvkKhcz8tlZG5HBQfReYZy46OwLcY+Zia0mtdHsOo9y/hP+CxMN0TU9QxoOtG4g==",
|
"integrity": "sha512-PmDi3uwK5nFuXh7XDTlVnS17xJS7vW36is2+w3xcv8SVxiB4NyATf4ctkVY5bkSjX0Y4nbvZCq1/EjtEyr9ktw==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"graceful-fs": "^4.2.0",
|
"graceful-fs": "^4.2.0",
|
||||||
"jsonfile": "^4.0.0",
|
"jsonfile": "^6.0.1",
|
||||||
"universalify": "^0.1.0"
|
"universalify": "^2.0.0"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=6 <7 || >=8"
|
"node": ">=14.14"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/fs-minipass": {
|
"node_modules/fs-minipass": {
|
||||||
@ -3038,27 +2827,6 @@
|
|||||||
"node": ">=12"
|
"node": ">=12"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/galactus/node_modules/jsonfile": {
|
|
||||||
"version": "6.1.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz",
|
|
||||||
"integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==",
|
|
||||||
"dev": true,
|
|
||||||
"dependencies": {
|
|
||||||
"universalify": "^2.0.0"
|
|
||||||
},
|
|
||||||
"optionalDependencies": {
|
|
||||||
"graceful-fs": "^4.1.6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/galactus/node_modules/universalify": {
|
|
||||||
"version": "2.0.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz",
|
|
||||||
"integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==",
|
|
||||||
"dev": true,
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 10.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/get-caller-file": {
|
"node_modules/get-caller-file": {
|
||||||
"version": "2.0.5",
|
"version": "2.0.5",
|
||||||
"resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz",
|
"resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz",
|
||||||
@ -3735,10 +3503,13 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/jsonfile": {
|
"node_modules/jsonfile": {
|
||||||
"version": "4.0.0",
|
"version": "6.1.0",
|
||||||
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-4.0.0.tgz",
|
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz",
|
||||||
"integrity": "sha512-m6F1R3z8jjlf2imQHS2Qez5sjKWQzbuuhuJ/FKYFRZvPE3PuHcSMVZzfsLhGVOkfd20obL5SWEBew5ShlquNxg==",
|
"integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
|
"dependencies": {
|
||||||
|
"universalify": "^2.0.0"
|
||||||
|
},
|
||||||
"optionalDependencies": {
|
"optionalDependencies": {
|
||||||
"graceful-fs": "^4.1.6"
|
"graceful-fs": "^4.1.6"
|
||||||
}
|
}
|
||||||
@ -3762,6 +3533,7 @@
|
|||||||
"version": "1.4.6",
|
"version": "1.4.6",
|
||||||
"resolved": "https://registry.npmjs.org/k8w-extend-native/-/k8w-extend-native-1.4.6.tgz",
|
"resolved": "https://registry.npmjs.org/k8w-extend-native/-/k8w-extend-native-1.4.6.tgz",
|
||||||
"integrity": "sha512-AHTCyFshldMme0s9FKD+QKG+QZdBkHXzl+8kYfNhsSDhcdQ5TYWQwphjecSJjxNdGd78TIbO0fHiOvM+Ei22YA==",
|
"integrity": "sha512-AHTCyFshldMme0s9FKD+QKG+QZdBkHXzl+8kYfNhsSDhcdQ5TYWQwphjecSJjxNdGd78TIbO0fHiOvM+Ei22YA==",
|
||||||
|
"dev": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"k8w-linq-array": "*",
|
"k8w-linq-array": "*",
|
||||||
"k8w-super-date": "*",
|
"k8w-super-date": "*",
|
||||||
@ -3771,17 +3543,20 @@
|
|||||||
"node_modules/k8w-linq-array": {
|
"node_modules/k8w-linq-array": {
|
||||||
"version": "0.2.8",
|
"version": "0.2.8",
|
||||||
"resolved": "https://registry.npmjs.org/k8w-linq-array/-/k8w-linq-array-0.2.8.tgz",
|
"resolved": "https://registry.npmjs.org/k8w-linq-array/-/k8w-linq-array-0.2.8.tgz",
|
||||||
"integrity": "sha512-4IAkQN8UJdk804tQi++wuwSZvFWk/Wcl1uG5PR/0c0YvB5hUd2f8tJm3OgOMOxjV9UVByNLvnPYGIwrFQPpjlA=="
|
"integrity": "sha512-4IAkQN8UJdk804tQi++wuwSZvFWk/Wcl1uG5PR/0c0YvB5hUd2f8tJm3OgOMOxjV9UVByNLvnPYGIwrFQPpjlA==",
|
||||||
|
"dev": true
|
||||||
},
|
},
|
||||||
"node_modules/k8w-super-date": {
|
"node_modules/k8w-super-date": {
|
||||||
"version": "0.1.3",
|
"version": "0.1.3",
|
||||||
"resolved": "https://registry.npmjs.org/k8w-super-date/-/k8w-super-date-0.1.3.tgz",
|
"resolved": "https://registry.npmjs.org/k8w-super-date/-/k8w-super-date-0.1.3.tgz",
|
||||||
"integrity": "sha512-IBqKOAMAXR/bgzu+rYI30tEMP/Y6Q8HQuqJiTkE2mLJg11yok9guoi8uZTynTahviVBndcfBpOgi1H/zhihv7w=="
|
"integrity": "sha512-IBqKOAMAXR/bgzu+rYI30tEMP/Y6Q8HQuqJiTkE2mLJg11yok9guoi8uZTynTahviVBndcfBpOgi1H/zhihv7w==",
|
||||||
|
"dev": true
|
||||||
},
|
},
|
||||||
"node_modules/k8w-super-object": {
|
"node_modules/k8w-super-object": {
|
||||||
"version": "0.3.0",
|
"version": "0.3.0",
|
||||||
"resolved": "https://registry.npmjs.org/k8w-super-object/-/k8w-super-object-0.3.0.tgz",
|
"resolved": "https://registry.npmjs.org/k8w-super-object/-/k8w-super-object-0.3.0.tgz",
|
||||||
"integrity": "sha512-u2jfh4goYXKZmSucaLaOTaNbLRatjv0CSRpzE0KU0732+9XtYZFd5vrdw/mzJfK5fPHb/zyikOSHDX5mJrav+g=="
|
"integrity": "sha512-u2jfh4goYXKZmSucaLaOTaNbLRatjv0CSRpzE0KU0732+9XtYZFd5vrdw/mzJfK5fPHb/zyikOSHDX5mJrav+g==",
|
||||||
|
"dev": true
|
||||||
},
|
},
|
||||||
"node_modules/keyv": {
|
"node_modules/keyv": {
|
||||||
"version": "4.5.4",
|
"version": "4.5.4",
|
||||||
@ -5280,27 +5055,6 @@
|
|||||||
"node": ">=12"
|
"node": ">=12"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/temp-file/node_modules/jsonfile": {
|
|
||||||
"version": "6.1.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz",
|
|
||||||
"integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==",
|
|
||||||
"dev": true,
|
|
||||||
"dependencies": {
|
|
||||||
"universalify": "^2.0.0"
|
|
||||||
},
|
|
||||||
"optionalDependencies": {
|
|
||||||
"graceful-fs": "^4.1.6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/temp-file/node_modules/universalify": {
|
|
||||||
"version": "2.0.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz",
|
|
||||||
"integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==",
|
|
||||||
"dev": true,
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 10.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/through": {
|
"node_modules/through": {
|
||||||
"version": "2.3.8",
|
"version": "2.3.8",
|
||||||
"resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz",
|
"resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz",
|
||||||
@ -5463,6 +5217,7 @@
|
|||||||
"version": "2.2.9",
|
"version": "2.2.9",
|
||||||
"resolved": "https://registry.npmjs.org/tsbuffer/-/tsbuffer-2.2.9.tgz",
|
"resolved": "https://registry.npmjs.org/tsbuffer/-/tsbuffer-2.2.9.tgz",
|
||||||
"integrity": "sha512-PZtbjmtMDziIi1/RPn1LMuMTmNUsZajB+Ziz+HxonAxswXeam0ukTwjQ2eYR6J1JOffz7E8z5ip+NrYZ7wGnBQ==",
|
"integrity": "sha512-PZtbjmtMDziIi1/RPn1LMuMTmNUsZajB+Ziz+HxonAxswXeam0ukTwjQ2eYR6J1JOffz7E8z5ip+NrYZ7wGnBQ==",
|
||||||
|
"dev": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"k8w-extend-native": "^1.4.6",
|
"k8w-extend-native": "^1.4.6",
|
||||||
"tsbuffer-validator": "^2.1.2",
|
"tsbuffer-validator": "^2.1.2",
|
||||||
@ -5498,12 +5253,14 @@
|
|||||||
"node_modules/tsbuffer-schema": {
|
"node_modules/tsbuffer-schema": {
|
||||||
"version": "2.2.0",
|
"version": "2.2.0",
|
||||||
"resolved": "https://registry.npmjs.org/tsbuffer-schema/-/tsbuffer-schema-2.2.0.tgz",
|
"resolved": "https://registry.npmjs.org/tsbuffer-schema/-/tsbuffer-schema-2.2.0.tgz",
|
||||||
"integrity": "sha512-I4+5Xfk7G+D++kXdNnYTeY26WQTaf14C84XQwPKteNmrwxRY3CQCkMqASRiCUqtpOuDn43qmoxuXpT+Vo8Wltg=="
|
"integrity": "sha512-I4+5Xfk7G+D++kXdNnYTeY26WQTaf14C84XQwPKteNmrwxRY3CQCkMqASRiCUqtpOuDn43qmoxuXpT+Vo8Wltg==",
|
||||||
|
"dev": true
|
||||||
},
|
},
|
||||||
"node_modules/tsbuffer-validator": {
|
"node_modules/tsbuffer-validator": {
|
||||||
"version": "2.1.2",
|
"version": "2.1.2",
|
||||||
"resolved": "https://registry.npmjs.org/tsbuffer-validator/-/tsbuffer-validator-2.1.2.tgz",
|
"resolved": "https://registry.npmjs.org/tsbuffer-validator/-/tsbuffer-validator-2.1.2.tgz",
|
||||||
"integrity": "sha512-PrqIYy7aANY7ssr92HJN8ZM+eGc4Qmpvu7nNBv+T2DOAb+eqblKjlDZEhNnzxjs/ddqu9PqPe4Aa+fqYdzo98g==",
|
"integrity": "sha512-PrqIYy7aANY7ssr92HJN8ZM+eGc4Qmpvu7nNBv+T2DOAb+eqblKjlDZEhNnzxjs/ddqu9PqPe4Aa+fqYdzo98g==",
|
||||||
|
"dev": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"k8w-extend-native": "^1.4.6",
|
"k8w-extend-native": "^1.4.6",
|
||||||
"tsbuffer-schema": "^2.2.0",
|
"tsbuffer-schema": "^2.2.0",
|
||||||
@ -5513,32 +5270,8 @@
|
|||||||
"node_modules/tslib": {
|
"node_modules/tslib": {
|
||||||
"version": "2.7.0",
|
"version": "2.7.0",
|
||||||
"resolved": "https://registry.npmjs.org/tslib/-/tslib-2.7.0.tgz",
|
"resolved": "https://registry.npmjs.org/tslib/-/tslib-2.7.0.tgz",
|
||||||
"integrity": "sha512-gLXCKdN1/j47AiHiOkJN69hJmcbGTHI0ImLmbYLHykhgeN0jVGola9yVjFgzCUklsZQMW55o+dW7IXv3RCXDzA=="
|
"integrity": "sha512-gLXCKdN1/j47AiHiOkJN69hJmcbGTHI0ImLmbYLHykhgeN0jVGola9yVjFgzCUklsZQMW55o+dW7IXv3RCXDzA==",
|
||||||
},
|
"dev": true
|
||||||
"node_modules/tsrpc": {
|
|
||||||
"version": "3.4.16",
|
|
||||||
"resolved": "https://registry.npmjs.org/tsrpc/-/tsrpc-3.4.16.tgz",
|
|
||||||
"integrity": "sha512-rUiaQNJJwZlOwTwnbZfNb2JJYL0Y/lZ/GVAtRYwFMzq7Z2H7dI4kB3oPakpu4+g3+i8radFPXfTsPkcNF1iAUg==",
|
|
||||||
"dependencies": {
|
|
||||||
"@types/ws": "^7.4.7",
|
|
||||||
"chalk": "^4.1.2",
|
|
||||||
"tsbuffer": "^2.2.9",
|
|
||||||
"tsrpc-base-client": "^2.1.15",
|
|
||||||
"tsrpc-proto": "^1.4.3",
|
|
||||||
"uuid": "^8.3.2",
|
|
||||||
"ws": "^7.5.9"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/tsrpc-base-client": {
|
|
||||||
"version": "2.1.15",
|
|
||||||
"resolved": "https://registry.npmjs.org/tsrpc-base-client/-/tsrpc-base-client-2.1.15.tgz",
|
|
||||||
"integrity": "sha512-ejIsGKF1MtcS2Mqpv1JYjoOmFbkOMaubb0FYglA52Sfl0glnq2UAqbCu5embQISzuIF9DiDeg1Rui9EyOc2hdA==",
|
|
||||||
"dependencies": {
|
|
||||||
"k8w-extend-native": "^1.4.6",
|
|
||||||
"tsbuffer": "^2.2.9",
|
|
||||||
"tslib": "*",
|
|
||||||
"tsrpc-proto": "^1.4.3"
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
"node_modules/tsrpc-cli": {
|
"node_modules/tsrpc-cli": {
|
||||||
"version": "2.4.5",
|
"version": "2.4.5",
|
||||||
@ -5582,18 +5315,6 @@
|
|||||||
"node": ">=12"
|
"node": ">=12"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/tsrpc-cli/node_modules/jsonfile": {
|
|
||||||
"version": "6.1.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz",
|
|
||||||
"integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==",
|
|
||||||
"dev": true,
|
|
||||||
"dependencies": {
|
|
||||||
"universalify": "^2.0.0"
|
|
||||||
},
|
|
||||||
"optionalDependencies": {
|
|
||||||
"graceful-fs": "^4.1.6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/tsrpc-cli/node_modules/typescript": {
|
"node_modules/tsrpc-cli/node_modules/typescript": {
|
||||||
"version": "4.9.5",
|
"version": "4.9.5",
|
||||||
"resolved": "https://registry.npmjs.org/typescript/-/typescript-4.9.5.tgz",
|
"resolved": "https://registry.npmjs.org/typescript/-/typescript-4.9.5.tgz",
|
||||||
@ -5607,52 +5328,16 @@
|
|||||||
"node": ">=4.2.0"
|
"node": ">=4.2.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/tsrpc-cli/node_modules/universalify": {
|
|
||||||
"version": "2.0.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz",
|
|
||||||
"integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==",
|
|
||||||
"dev": true,
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 10.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/tsrpc-proto": {
|
"node_modules/tsrpc-proto": {
|
||||||
"version": "1.4.3",
|
"version": "1.4.3",
|
||||||
"resolved": "https://registry.npmjs.org/tsrpc-proto/-/tsrpc-proto-1.4.3.tgz",
|
"resolved": "https://registry.npmjs.org/tsrpc-proto/-/tsrpc-proto-1.4.3.tgz",
|
||||||
"integrity": "sha512-qtkk5i34m9/K1258EdyXAEikU/ADPELHCCXN/oFJ4XwH+kN3kXnKYmwCDblUuMA73V2+A/EwkgUGyAgPa335Hw==",
|
"integrity": "sha512-qtkk5i34m9/K1258EdyXAEikU/ADPELHCCXN/oFJ4XwH+kN3kXnKYmwCDblUuMA73V2+A/EwkgUGyAgPa335Hw==",
|
||||||
|
"dev": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"tsbuffer-schema": "^2.2.0",
|
"tsbuffer-schema": "^2.2.0",
|
||||||
"tslib": "*"
|
"tslib": "*"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/tsrpc/node_modules/@types/ws": {
|
|
||||||
"version": "7.4.7",
|
|
||||||
"resolved": "https://registry.npmjs.org/@types/ws/-/ws-7.4.7.tgz",
|
|
||||||
"integrity": "sha512-JQbbmxZTZehdc2iszGKs5oC3NFnjeay7mtAWrdt7qNtAVK0g19muApzAy4bm9byz79xa2ZnO/BOBC2R8RC5Lww==",
|
|
||||||
"dependencies": {
|
|
||||||
"@types/node": "*"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/tsrpc/node_modules/ws": {
|
|
||||||
"version": "7.5.10",
|
|
||||||
"resolved": "https://registry.npmjs.org/ws/-/ws-7.5.10.tgz",
|
|
||||||
"integrity": "sha512-+dbF1tHwZpXcbOJdVOkzLDxZP1ailvSxM6ZweXTegylPny803bFhA+vqBYw4s31NSAk4S2Qz+AKXK9a4wkdjcQ==",
|
|
||||||
"engines": {
|
|
||||||
"node": ">=8.3.0"
|
|
||||||
},
|
|
||||||
"peerDependencies": {
|
|
||||||
"bufferutil": "^4.0.1",
|
|
||||||
"utf-8-validate": "^5.0.2"
|
|
||||||
},
|
|
||||||
"peerDependenciesMeta": {
|
|
||||||
"bufferutil": {
|
|
||||||
"optional": true
|
|
||||||
},
|
|
||||||
"utf-8-validate": {
|
|
||||||
"optional": true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/type-fest": {
|
"node_modules/type-fest": {
|
||||||
"version": "0.13.1",
|
"version": "0.13.1",
|
||||||
"resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.13.1.tgz",
|
"resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.13.1.tgz",
|
||||||
@ -5707,15 +5392,16 @@
|
|||||||
"node_modules/undici-types": {
|
"node_modules/undici-types": {
|
||||||
"version": "6.19.8",
|
"version": "6.19.8",
|
||||||
"resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.19.8.tgz",
|
"resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.19.8.tgz",
|
||||||
"integrity": "sha512-ve2KP6f/JnbPBFyobGHuerC9g1FYGn/F8n1LWTwNxCEzd6IfqTwUQcNXgEtmmQ6DlRrC1hrSrBnCZPokRrDHjw=="
|
"integrity": "sha512-ve2KP6f/JnbPBFyobGHuerC9g1FYGn/F8n1LWTwNxCEzd6IfqTwUQcNXgEtmmQ6DlRrC1hrSrBnCZPokRrDHjw==",
|
||||||
|
"dev": true
|
||||||
},
|
},
|
||||||
"node_modules/universalify": {
|
"node_modules/universalify": {
|
||||||
"version": "0.1.2",
|
"version": "2.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/universalify/-/universalify-0.1.2.tgz",
|
"resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz",
|
||||||
"integrity": "sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==",
|
"integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">= 4.0.0"
|
"node": ">= 10.0.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/untildify": {
|
"node_modules/untildify": {
|
||||||
@ -5748,14 +5434,6 @@
|
|||||||
"integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==",
|
"integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==",
|
||||||
"dev": true
|
"dev": true
|
||||||
},
|
},
|
||||||
"node_modules/uuid": {
|
|
||||||
"version": "8.3.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/uuid/-/uuid-8.3.2.tgz",
|
|
||||||
"integrity": "sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg==",
|
|
||||||
"bin": {
|
|
||||||
"uuid": "dist/bin/uuid"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/v8-compile-cache-lib": {
|
"node_modules/v8-compile-cache-lib": {
|
||||||
"version": "3.0.1",
|
"version": "3.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/v8-compile-cache-lib/-/v8-compile-cache-lib-3.0.1.tgz",
|
"resolved": "https://registry.npmjs.org/v8-compile-cache-lib/-/v8-compile-cache-lib-3.0.1.tgz",
|
||||||
|
12
package.json
12
package.json
@ -3,18 +3,20 @@
|
|||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
"main": "dist/electron/main.js",
|
"main": "dist/electron/main.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"start": "electron .",
|
"start": "cross-env NODE_ENV=dev electron .",
|
||||||
"build": "tsc && copyfiles -u 1 src/electron/index.html dist/ && copyfiles -u 1 src/electron/index.css dist/",
|
"build": "cross-env NODE_ENV=prod tsc && npm run copyfiles",
|
||||||
|
"copyfiles": "copyfiles -u 1 src/electron/index.html dist/ && copyfiles -u 1 src/electron/index.css dist/ && copyfiles -u 1 shared/jsons/* dist/shared",
|
||||||
"buildexe": "npm run build && electron-builder",
|
"buildexe": "npm run build && electron-builder",
|
||||||
"api": "tsrpc-cli proto && tsrpc-cli api",
|
|
||||||
"watch": "nodemon"
|
"watch": "nodemon"
|
||||||
},
|
},
|
||||||
"build": {
|
"build": {
|
||||||
"appId": "SDServer",
|
"appId": "SDServer",
|
||||||
|
"productName": "SDServer",
|
||||||
"files": [
|
"files": [
|
||||||
"dist/**/*",
|
"dist/**/*",
|
||||||
"node_modules/**/*",
|
"node_modules/**/*",
|
||||||
"package.json"
|
"package.json",
|
||||||
|
".env.prod"
|
||||||
],
|
],
|
||||||
"directories": {
|
"directories": {
|
||||||
"output": "release"
|
"output": "release"
|
||||||
@ -24,13 +26,13 @@
|
|||||||
"dayjs": "^1.11.13",
|
"dayjs": "^1.11.13",
|
||||||
"dotenv": "^16.4.5",
|
"dotenv": "^16.4.5",
|
||||||
"module-alias": "^2.2.3",
|
"module-alias": "^2.2.3",
|
||||||
"tsrpc": "^3.4.16",
|
|
||||||
"ws": "^8.18.0"
|
"ws": "^8.18.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@types/node": "^22.5.0",
|
"@types/node": "^22.5.0",
|
||||||
"@types/ws": "^8.5.12",
|
"@types/ws": "^8.5.12",
|
||||||
"copyfiles": "^2.4.1",
|
"copyfiles": "^2.4.1",
|
||||||
|
"cross-env": "^7.0.3",
|
||||||
"electron": "^32.0.1",
|
"electron": "^32.0.1",
|
||||||
"electron-builder": "^24.7.0",
|
"electron-builder": "^24.7.0",
|
||||||
"electron-packager": "^17.1.2",
|
"electron-packager": "^17.1.2",
|
||||||
|
25
shared/jsons/slot1.json
Normal file
25
shared/jsons/slot1.json
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
{
|
||||||
|
"slotData": [
|
||||||
|
{"slot":[11,4,8,9,5,2,13,10,7,9,10,6,6,12,4],"line":[[[5,11,12],161,200]]},
|
||||||
|
{"slot":[9,6,2,5,4,14,10,9,13,10,4,5,5,2,2]},
|
||||||
|
{"slot":[4,3,3,3,9,10,14,14,9,4,7,8,8,5,10],"free":[[1,2,3],3],"scatter":[[[1,2,3],300]]},
|
||||||
|
{"slot":[1,2,4,5,6,7,3,3,3,8,9,10,11,12,13],"free":[[6,7,8],10],"scatter":[[[6,7,8],300]]}
|
||||||
|
],
|
||||||
|
"slotFreeData": [
|
||||||
|
{"slot":[9,9,10,13,4,5,4,3,4,11,10,14,14,14,5]},
|
||||||
|
{"slot":[12,6,8,12,11,7,12,11,5,5,11,5,3,10,9]},
|
||||||
|
{"slot":[4,6,11,13,8,12,12,3,4,10,7,5,14,14,4]},
|
||||||
|
{"slot":[12,11,9,14,6,7,2,3,8,8,11,10,10,7,14]},
|
||||||
|
{"slot":[9,14,13,4,11,4,7,6,14,6,12,13,9,12,12]},
|
||||||
|
{"slot":[10,3,12,13,5,6,4,8,4,9,13,14,11,14,4]},
|
||||||
|
{"slot":[11,13,9,8,5,8,5,5,13,9,14,9,12,4,7]},
|
||||||
|
{"slot":[10,14,13,9,8,6,6,6,4,13,13,12,9,14,4],"line":[[[5,6,7],122,300]]},
|
||||||
|
{"slot":[13,9,5,14,4,9,4,12,12,11,4,14,8,7,6],"line":[[[10,6],195,300],[[10,6],213,300]]},
|
||||||
|
{"slot":[5,9,9,3,11,10,4,5,12,5,4,14,12,5,9],"line":[[[10,6],195,300],[[10,6],213,300]]},
|
||||||
|
{"slot":[2,8,13,2,10,9,12,5,11,4,5,2,12,5,8],"line":[[[0,6,12],49,150],[[0,11,2],61,150],[[0,11,7,13],70,3000],[[0,11,12],79,150],[[10,11,7,13],234,3000]]},
|
||||||
|
{"slot":[5,12,13,3,4,10,2,5,8,8,2,9,12,10,9],"line":[[[10,1,12],183,150],[[10,6,2],195,150],[[10,6,12],213,150]]},
|
||||||
|
{"slot":[14,4,10,3,11,5,14,3,12,6,10,6,14,5,12],"line":[[[0,6,12],49,750]],"scatter":[[[3,7],300]]},
|
||||||
|
{"slot":[6,3,12,4,8,14,10,3,7,9,10,4,10,6,7],"line":[[[10,6,12],213,75]],"scatter":[[[1,7],300]]},
|
||||||
|
{"slot":[9,12,3,7,2,6,13,11,3,11,13,3,8,6,6],"free":[[2,8,11],10],"scatter":[[[2,8,11],900]]}
|
||||||
|
]
|
||||||
|
}
|
12
src/Utils/tools.ts
Normal file
12
src/Utils/tools.ts
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
import { app } from 'electron';
|
||||||
|
import path from 'path';
|
||||||
|
|
||||||
|
export function getExternalJsonPath(filename: string): string {
|
||||||
|
if (process.env.NODE_ENV === 'dev') {
|
||||||
|
// 开发模式下使用相对路径
|
||||||
|
return path.join(__dirname, '../../shared/jsons', filename);
|
||||||
|
} else {
|
||||||
|
// 生产模式下使用外部路径
|
||||||
|
return path.join(app.getPath('userData'), 'jsons', filename);
|
||||||
|
}
|
||||||
|
}
|
@ -3,7 +3,6 @@ import { INetResponse } from "../../script/Engine/CatanEngine/NetManagerV2/Core/
|
|||||||
import { ClientData } from "../../shared/protocols/define/interface";
|
import { ClientData } from "../../shared/protocols/define/interface";
|
||||||
import { RpcSlotInRequest, RpcSlotInResponse } from "../../shared/protocols/SlotRequest";
|
import { RpcSlotInRequest, RpcSlotInResponse } from "../../shared/protocols/SlotRequest";
|
||||||
|
|
||||||
|
|
||||||
export default abstract class SlotInBase {
|
export default abstract class SlotInBase {
|
||||||
protected ver: string = "";
|
protected ver: string = "";
|
||||||
protected abstract db: number;
|
protected abstract db: number;
|
||||||
@ -12,8 +11,8 @@ export default abstract class SlotInBase {
|
|||||||
|
|
||||||
public *in(clientData: ClientData, req: INetRequest<RpcSlotInRequest>): IterableIterator<any> {
|
public *in(clientData: ClientData, req: INetRequest<RpcSlotInRequest>): IterableIterator<any> {
|
||||||
const data: RpcSlotInRequest = req.Data;
|
const data: RpcSlotInRequest = req.Data;
|
||||||
const { id } = data;
|
|
||||||
const { ver, db, br, jp } = this;
|
const { ver, db, br, jp } = this;
|
||||||
|
|
||||||
const response: INetResponse<RpcSlotInResponse> = {
|
const response: INetResponse<RpcSlotInResponse> = {
|
||||||
Status: 0,
|
Status: 0,
|
||||||
Method: req.Method,
|
Method: req.Method,
|
||||||
|
@ -1,9 +1,10 @@
|
|||||||
|
import * as fs from 'fs';
|
||||||
import { INetRequest } from "../../script/Engine/CatanEngine/NetManagerV2/Core/INetRequest";
|
import { INetRequest } from "../../script/Engine/CatanEngine/NetManagerV2/Core/INetRequest";
|
||||||
import { INetResponse } from "../../script/Engine/CatanEngine/NetManagerV2/Core/INetResponse";
|
import { INetResponse } from "../../script/Engine/CatanEngine/NetManagerV2/Core/INetResponse";
|
||||||
import { ClientData } from "../../shared/protocols/define/interface";
|
import { ClientData } from "../../shared/protocols/define/interface";
|
||||||
import { RpcSlot1SpinRequest, RpcSlot1SpinResponse } from "../../shared/protocols/Slot1Request";
|
import { RpcSlot1SpinRequest, RpcSlot1SpinResponse } from "../../shared/protocols/Slot1Request";
|
||||||
import { RandomEx } from "../../Utils/Number/RandomEx";
|
import { RandomEx } from "../../Utils/Number/RandomEx";
|
||||||
|
import { getExternalJsonPath } from "../../Utils/tools";
|
||||||
|
|
||||||
export default abstract class SlotSpinBase {
|
export default abstract class SlotSpinBase {
|
||||||
protected abstract ID: number;
|
protected abstract ID: number;
|
||||||
@ -11,14 +12,30 @@ export default abstract class SlotSpinBase {
|
|||||||
protected IsHaveReSpin: boolean = false;
|
protected IsHaveReSpin: boolean = false;
|
||||||
protected IsHaveRetriggerFreeSpin: boolean = false;
|
protected IsHaveRetriggerFreeSpin: boolean = false;
|
||||||
protected FreeMax: number = 50;
|
protected FreeMax: number = 50;
|
||||||
protected abstract Temps: string[];
|
protected JsonData: any;
|
||||||
protected abstract FreeTemps: string[];
|
protected get Temps(): string[] { return this.JsonData.slotData };
|
||||||
|
protected get FreeTemps(): string[] { return this.JsonData.slotFreeData };
|
||||||
|
|
||||||
public *spin(clientData: ClientData, req: INetRequest<RpcSlot1SpinRequest>): IterableIterator<any> {
|
public *spin(clientData: ClientData, req: INetRequest<RpcSlot1SpinRequest>): IterableIterator<any> {
|
||||||
|
const self = this;
|
||||||
const data: RpcSlot1SpinRequest = req.Data
|
const data: RpcSlot1SpinRequest = req.Data
|
||||||
|
|
||||||
|
if (!clientData.jsons[this.ID]) {
|
||||||
|
let slotData: any;
|
||||||
|
let AsyncFunction = async function () {
|
||||||
|
slotData = await self.GetTemps();
|
||||||
|
};
|
||||||
|
AsyncFunction();
|
||||||
|
while (!slotData) {
|
||||||
|
yield;
|
||||||
|
}
|
||||||
|
clientData.jsons[this.ID] = slotData;
|
||||||
|
}
|
||||||
|
this.JsonData = clientData.jsons[this.ID];
|
||||||
|
|
||||||
clientData.free = null;
|
clientData.free = null;
|
||||||
|
|
||||||
const slotData: any = JSON.parse(this.Temps[RandomEx.GetInt(0, this.Temps.length)]);
|
const slotData: any = this.Temps[RandomEx.GetInt(0, this.Temps.length)];
|
||||||
|
|
||||||
let totalGet: number = 0;
|
let totalGet: number = 0;
|
||||||
if (slotData.line) {
|
if (slotData.line) {
|
||||||
@ -57,7 +74,7 @@ export default abstract class SlotSpinBase {
|
|||||||
let freeData = [];
|
let freeData = [];
|
||||||
let totalFreeGet = 0;
|
let totalFreeGet = 0;
|
||||||
for (let i: number = 0; i < count; i++) {
|
for (let i: number = 0; i < count; i++) {
|
||||||
const slotData: any = JSON.parse(this.FreeTemps[RandomEx.GetInt(0, this.FreeTemps.length)]);
|
const slotData: any = this.FreeTemps[RandomEx.GetInt(0, this.FreeTemps.length)];
|
||||||
freeData.push(slotData);
|
freeData.push(slotData);
|
||||||
if (slotData.line) {
|
if (slotData.line) {
|
||||||
totalFreeGet += this.getLineGet(slotData.line);
|
totalFreeGet += this.getLineGet(slotData.line);
|
||||||
@ -90,6 +107,14 @@ export default abstract class SlotSpinBase {
|
|||||||
let totalGet: number = scatter[0][1];
|
let totalGet: number = scatter[0][1];
|
||||||
return totalGet;
|
return totalGet;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
protected async GetTemps(): Promise<any> {
|
||||||
|
const filePath = getExternalJsonPath(`slot${this.ID}.json`);
|
||||||
|
console.log('filePath', filePath);
|
||||||
|
const data = await fs.promises.readFile(filePath, 'utf-8');
|
||||||
|
const jsonData = JSON.parse(data);
|
||||||
|
return jsonData;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1,32 +1,7 @@
|
|||||||
import SlotSpinBase from "../slot/spin";
|
import SlotSpinBase from "../slot/SlotSpinBase";
|
||||||
|
|
||||||
|
|
||||||
export default class SlotSpin1 extends SlotSpinBase {
|
export default class SlotSpin1 extends SlotSpinBase {
|
||||||
protected ID: number = 1;
|
protected ID: number = 1;
|
||||||
protected IsHaveFreeSpin: boolean = true;
|
protected IsHaveFreeSpin: boolean = true;
|
||||||
protected IsHaveRetriggerFreeSpin: boolean = true;
|
protected IsHaveRetriggerFreeSpin: boolean = true;
|
||||||
|
|
||||||
protected Temps: string[] = [
|
|
||||||
`{"slot":[11,4,8,9,5,2,13,10,7,9,10,6,6,12,4],"line":[[[5,11,12],161,200]]}`,
|
|
||||||
`{"slot":[9,6,2,5,4,14,10,9,13,10,4,5,5,2,2]}`,
|
|
||||||
`{"slot":[4,3,3,3,9,10,14,14,9,4,7,8,8,5,10],"free":[[1,2,3],3],"scatter":[[[1,2,3],300]]}`,
|
|
||||||
`{"slot":[1,2,4,5,6,7,3,3,3,8,9,10,11,12,13],"free":[[6,7,8],10],"scatter":[[[6,7,8],300]]}`,
|
|
||||||
];
|
|
||||||
protected FreeTemps: string[] = [
|
|
||||||
`{"slot":[9,9,10,13,4,5,4,3,4,11,10,14,14,14,5]}`,
|
|
||||||
`{"slot":[12,6,8,12,11,7,12,11,5,5,11,5,3,10,9]}`,
|
|
||||||
`{"slot":[4,6,11,13,8,12,12,3,4,10,7,5,14,14,4]}`,
|
|
||||||
`{"slot":[12,11,9,14,6,7,2,3,8,8,11,10,10,7,14]}`,
|
|
||||||
`{"slot":[9,14,13,4,11,4,7,6,14,6,12,13,9,12,12]}`,
|
|
||||||
`{"slot":[10,3,12,13,5,6,4,8,4,9,13,14,11,14,4]}`,
|
|
||||||
`{"slot":[11,13,9,8,5,8,5,5,13,9,14,9,12,4,7]}`,
|
|
||||||
// `{"slot":[10,14,13,9,8,6,6,6,4,13,13,12,9,14,4],"line":[[[5,6,7],122,300]]}`,
|
|
||||||
// `{"slot":[13,9,5,14,4,9,4,12,12,11,4,14,8,7,6],"line":[[[10,6],195,300],[[10,6],213,300]]}`,
|
|
||||||
// `{"slot":[5,9,9,3,11,10,4,5,12,5,4,14,12,5,9],"line":[[[10,6],195,300],[[10,6],213,300]]}`,
|
|
||||||
// `{"slot":[2,8,13,2,10,9,12,5,11,4,5,2,12,5,8],"line":[[[0,6,12],49,150],[[0,11,2],61,150],[[0,11,7,13],70,3000],[[0,11,12],79,150],[[10,11,7,13],234,3000]]}`,
|
|
||||||
// `{"slot":[5,12,13,3,4,10,2,5,8,8,2,9,12,10,9],"line":[[[10,1,12],183,150],[[10,6,2],195,150],[[10,6,12],213,150]]}`,
|
|
||||||
`{"slot":[14,4,10,3,11,5,14,3,12,6,10,6,14,5,12],"line":[[[0,6,12],49,750]],"scatter":[[[3,7],300]]}`,
|
|
||||||
`{"slot":[6,3,12,4,8,14,10,3,7,9,10,4,10,6,7],"line":[[[10,6,12],213,75]],"scatter":[[[1,7],300]]}`,
|
|
||||||
`{"slot":[9,12,3,7,2,6,13,11,3,11,13,3,8,6,6],"free":[[2,8,11],10],"scatter":[[[2,8,11],900]]}`,
|
|
||||||
];
|
|
||||||
}
|
}
|
@ -19,6 +19,7 @@
|
|||||||
<input type="number" id="port" value="8080">
|
<input type="number" id="port" value="8080">
|
||||||
<button id="startBtn">啟動</button>
|
<button id="startBtn">啟動</button>
|
||||||
<button id="stopBtn">關閉</button>
|
<button id="stopBtn">關閉</button>
|
||||||
|
<button id="jsonReload">重載Json</button>
|
||||||
<button id="devToolsBtn">DevTools</button>
|
<button id="devToolsBtn">DevTools</button>
|
||||||
<p id="status">Status: Waiting for actions...</p>
|
<p id="status">Status: Waiting for actions...</p>
|
||||||
</div>
|
</div>
|
||||||
|
@ -7,6 +7,7 @@ import "module-alias/register";
|
|||||||
|
|
||||||
import dotenv from 'dotenv';
|
import dotenv from 'dotenv';
|
||||||
import { app, BrowserWindow, ipcMain } from 'electron';
|
import { app, BrowserWindow, ipcMain } from 'electron';
|
||||||
|
import fs from 'fs';
|
||||||
import * as path from 'path';
|
import * as path from 'path';
|
||||||
import { WebSocketServer } from 'ws';
|
import { WebSocketServer } from 'ws';
|
||||||
import { BaseEnumerator } from "../CatanEngine/CoroutineV2/Core/BaseEnumerator";
|
import { BaseEnumerator } from "../CatanEngine/CoroutineV2/Core/BaseEnumerator";
|
||||||
@ -16,8 +17,15 @@ onload();
|
|||||||
|
|
||||||
function onload() {
|
function onload() {
|
||||||
BaseEnumerator.Init();
|
BaseEnumerator.Init();
|
||||||
|
setLog();
|
||||||
// Load environment variables from .env file
|
// Load environment variables from .env file
|
||||||
dotenv.config();
|
const filePath = ".env.dev";
|
||||||
|
// 检查文件是否存在
|
||||||
|
if (fs.existsSync(filePath)) {
|
||||||
|
dotenv.config({ path: `.env.dev` });
|
||||||
|
} else {
|
||||||
|
dotenv.config({ path: path.resolve(__dirname, `../../.env.prod`) });
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
let server: WebSocketServer | null = null;
|
let server: WebSocketServer | null = null;
|
||||||
@ -61,38 +69,39 @@ app.on('window-all-closed', () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
// 启动 WebSocket 服务器
|
// 启动 WebSocket 服务器
|
||||||
ipcMain.on('start-websocket', (event, portNumber: number) => {
|
ipcMain.on('start-websocket', (event: Electron.IpcMainEvent, portNumber: number) => {
|
||||||
if (server) {
|
if (server) {
|
||||||
server.close();
|
closeServer(event);
|
||||||
}
|
}
|
||||||
|
|
||||||
port = portNumber || 8080;
|
port = portNumber || 8080;
|
||||||
|
|
||||||
server = new WebSocketServer({ port: port });
|
server = new WebSocketServer({ port });
|
||||||
|
|
||||||
server.on('connection', NetConnector.OnWebSocketConnection);
|
server.on('connection', NetConnector.OnWebSocketConnection);
|
||||||
|
|
||||||
// server.on('connection', (socket, request) => {
|
|
||||||
// const ip = request.socket.remoteAddress.replace("::ffff:", "") || 'Unknown IP';
|
|
||||||
// console.log(`Client connected from IP: ${ip}`);
|
|
||||||
// socket.send('Welcome to the WebSocket server');
|
|
||||||
|
|
||||||
// socket.on('message', (message: string) => {
|
|
||||||
// console.log(`[RPC] 收到client呼叫: ${message}`);
|
|
||||||
// socket.send(`Server received your message: ${message}`);
|
|
||||||
// console.log(`[RPC] 回傳client呼叫: ${message}`);
|
|
||||||
// });
|
|
||||||
|
|
||||||
// socket.on('close', () => {
|
|
||||||
// console.log('Client disconnected');
|
|
||||||
// });
|
|
||||||
// });
|
|
||||||
|
|
||||||
event.reply('websocket-status', `WebSocket server started on port ${port}`);
|
event.reply('websocket-status', `WebSocket server started on port ${port}`);
|
||||||
});
|
});
|
||||||
|
|
||||||
// 关闭 WebSocket 服务器
|
// 关闭 WebSocket 服务器
|
||||||
ipcMain.on('stop-websocket', (event) => {
|
ipcMain.on('stop-websocket', (event: Electron.IpcMainEvent) => {
|
||||||
|
closeServer(event);
|
||||||
|
});
|
||||||
|
|
||||||
|
// 打开开发者工具
|
||||||
|
ipcMain.on('json-reload', () => {
|
||||||
|
NetConnector.clients.forEach(client => {
|
||||||
|
client.jsons = {};
|
||||||
|
});
|
||||||
|
console.log(`重載成功`);
|
||||||
|
});
|
||||||
|
|
||||||
|
// 打开开发者工具
|
||||||
|
ipcMain.on('open-devtools', () => {
|
||||||
|
mainWindow.webContents.openDevTools();
|
||||||
|
});
|
||||||
|
|
||||||
|
function closeServer(event: Electron.IpcMainEvent) {
|
||||||
if (server) {
|
if (server) {
|
||||||
server.clients.forEach(client => {
|
server.clients.forEach(client => {
|
||||||
if (client.readyState === 1) {
|
if (client.readyState === 1) {
|
||||||
@ -102,51 +111,47 @@ ipcMain.on('stop-websocket', (event) => {
|
|||||||
server.close((err) => {
|
server.close((err) => {
|
||||||
if (err) {
|
if (err) {
|
||||||
event.reply('websocket-status', 'Failed to stop WebSocket server');
|
event.reply('websocket-status', 'Failed to stop WebSocket server');
|
||||||
} else {
|
|
||||||
event.reply('websocket-status', 'WebSocket server stopped');
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
event.reply('websocket-status', 'WebSocket server stopped');
|
||||||
} else {
|
} else {
|
||||||
event.reply('websocket-status', 'No WebSocket server is running');
|
event.reply('websocket-status', 'No WebSocket server is running');
|
||||||
}
|
}
|
||||||
});
|
}
|
||||||
|
|
||||||
// 打开开发者工具
|
|
||||||
ipcMain.on('open-devtools', () => {
|
|
||||||
mainWindow.webContents.openDevTools();
|
|
||||||
});
|
|
||||||
|
|
||||||
// Create a function to send log messages to the renderer
|
// Create a function to send log messages to the renderer
|
||||||
function sendLogToRenderer(window: BrowserWindow, message: string, color: string) {
|
function sendLogToRenderer(window: BrowserWindow, message: string, color: string) {
|
||||||
window.webContents.send('log-message', [message, color]);
|
window.webContents.send('log-message', [message, color]);
|
||||||
}
|
}
|
||||||
|
|
||||||
// 重寫 console.log 方法以便將訊息發送到渲染進程
|
function setLog() {
|
||||||
const originalConsoleLog = console.log;
|
// 重寫 console.log 方法以便將訊息發送到渲染進程
|
||||||
console.log = (...args: any[]) => {
|
const originalConsoleLog = console.log;
|
||||||
const message = args.join(' ');
|
console.log = (...args: any[]) => {
|
||||||
originalConsoleLog(message); // 保留原始行為
|
const message = args.join(' ');
|
||||||
if (BrowserWindow.getAllWindows().length > 0) {
|
originalConsoleLog(message); // 保留原始行為
|
||||||
sendLogToRenderer(BrowserWindow.getAllWindows()[0], message, "green"); // 發送訊息到渲染進程
|
if (BrowserWindow.getAllWindows().length > 0) {
|
||||||
}
|
sendLogToRenderer(BrowserWindow.getAllWindows()[0], message, "green"); // 發送訊息到渲染進程
|
||||||
};
|
}
|
||||||
|
};
|
||||||
|
|
||||||
// 重写 console.warn
|
// 重写 console.warn
|
||||||
const originalConsoleWarn = console.warn;
|
const originalConsoleWarn = console.warn;
|
||||||
console.warn = (...args: any[]) => {
|
console.warn = (...args: any[]) => {
|
||||||
const message = args.join(' ');
|
const message = args.join(' ');
|
||||||
originalConsoleWarn(message);
|
originalConsoleWarn(message);
|
||||||
if (BrowserWindow.getAllWindows().length > 0) {
|
if (BrowserWindow.getAllWindows().length > 0) {
|
||||||
sendLogToRenderer(BrowserWindow.getAllWindows()[0], message, "yellow"); // 發送訊息到渲染進程
|
sendLogToRenderer(BrowserWindow.getAllWindows()[0], message, "yellow"); // 發送訊息到渲染進程
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
// 重写 console.error
|
// 重写 console.error
|
||||||
const originalConsoleError = console.error;
|
const originalConsoleError = console.error;
|
||||||
console.error = (...args: any[]) => {
|
console.error = (...args: any[]) => {
|
||||||
const message = args.join(' ');
|
const message = args.join(' ');
|
||||||
originalConsoleError(message);
|
originalConsoleError(message);
|
||||||
if (BrowserWindow.getAllWindows().length > 0) {
|
if (BrowserWindow.getAllWindows().length > 0) {
|
||||||
sendLogToRenderer(BrowserWindow.getAllWindows()[0], message, "red"); // 發送訊息到渲染進程
|
sendLogToRenderer(BrowserWindow.getAllWindows()[0], message, "red"); // 發送訊息到渲染進程
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
}
|
@ -5,6 +5,7 @@ import { contextBridge, ipcRenderer } from 'electron';
|
|||||||
contextBridge.exposeInMainWorld('electron', {
|
contextBridge.exposeInMainWorld('electron', {
|
||||||
startWebSocket: (port: number) => ipcRenderer.send('start-websocket', port),
|
startWebSocket: (port: number) => ipcRenderer.send('start-websocket', port),
|
||||||
stopWebSocket: () => ipcRenderer.send('stop-websocket'),
|
stopWebSocket: () => ipcRenderer.send('stop-websocket'),
|
||||||
|
jsonReload: () => ipcRenderer.send('json-reload'),
|
||||||
openDevTools: () => ipcRenderer.send('open-devtools'),
|
openDevTools: () => ipcRenderer.send('open-devtools'),
|
||||||
onWebSocketStatus: (callback: (message: string) => void) => ipcRenderer.on('websocket-status', (event, message) => callback(message)),
|
onWebSocketStatus: (callback: (message: string) => void) => ipcRenderer.on('websocket-status', (event, message) => callback(message)),
|
||||||
onLogMessage: (callback: (message: string, color: string) => void) => ipcRenderer.on('log-message', (event, [message, color]) => callback(message, color)),
|
onLogMessage: (callback: (message: string, color: string) => void) => ipcRenderer.on('log-message', (event, [message, color]) => callback(message, color)),
|
||||||
|
@ -56,6 +56,10 @@ document.getElementById('stopBtn')?.addEventListener('click', () => {
|
|||||||
window.electron.stopWebSocket();
|
window.electron.stopWebSocket();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
document.getElementById('jsonReload')?.addEventListener('click', () => {
|
||||||
|
window.electron.jsonReload();
|
||||||
|
});
|
||||||
|
|
||||||
document.getElementById('devToolsBtn')?.addEventListener('click', () => {
|
document.getElementById('devToolsBtn')?.addEventListener('click', () => {
|
||||||
window.electron.openDevTools();
|
window.electron.openDevTools();
|
||||||
});
|
});
|
||||||
|
1
src/global.d.ts
vendored
1
src/global.d.ts
vendored
@ -3,6 +3,7 @@ interface Window {
|
|||||||
electron: {
|
electron: {
|
||||||
startWebSocket: (port: number) => void;
|
startWebSocket: (port: number) => void;
|
||||||
stopWebSocket: () => void;
|
stopWebSocket: () => void;
|
||||||
|
jsonReload: () => void;
|
||||||
openDevTools: () => void;
|
openDevTools: () => void;
|
||||||
onWebSocketStatus: (callback: (message: string) => void) => void;
|
onWebSocketStatus: (callback: (message: string) => void) => void;
|
||||||
onLogMessage: (callback: (message: string, color: string) => void) => void; // 添加這行以處理日誌消息
|
onLogMessage: (callback: (message: string, color: string) => void) => void; // 添加這行以處理日誌消息
|
||||||
|
@ -16,7 +16,7 @@ ws://127.0.0.1:9005
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
const port: number = process.env.PORT ? parseInt(process.env.PORT, 10) : 8080; // 默认端口为 8080
|
const port: number = process.env.PORT ? parseInt(process.env.PORT, 10) : 8080; // 默认端口为 8080
|
||||||
const server = new WebSocketServer({ port: 8080 });
|
const server = new WebSocketServer({ port });
|
||||||
|
|
||||||
// server.on('connection', (socket: WebSocket) => {
|
// server.on('connection', (socket: WebSocket) => {
|
||||||
// console.log('客户端已连接');
|
// console.log('客户端已连接');
|
||||||
|
@ -19,7 +19,7 @@ export class NetConnector {
|
|||||||
const ip = request.socket.remoteAddress.replace("::ffff:", "") || 'Unknown IP';
|
const ip = request.socket.remoteAddress.replace("::ffff:", "") || 'Unknown IP';
|
||||||
console.log(`Client connected from IP: ${ip}`);
|
console.log(`Client connected from IP: ${ip}`);
|
||||||
|
|
||||||
NetConnector.clients.set(socket, { socket, id: id, name: "", money: 0 });
|
NetConnector.clients.set(socket, { socket, id: id, name: "", money: 0, jsons: {} });
|
||||||
id++;
|
id++;
|
||||||
|
|
||||||
socket.on('message', (message: Buffer) => NetConnector.OnWebSocketMessage(socket, message));
|
socket.on('message', (message: Buffer) => NetConnector.OnWebSocketMessage(socket, message));
|
||||||
|
@ -6,5 +6,6 @@ export interface ClientData {
|
|||||||
id: number;
|
id: number;
|
||||||
name: string;
|
name: string;
|
||||||
money: number;
|
money: number;
|
||||||
|
jsons: { [key: number]: any; };
|
||||||
free?: { count: number, freeData: any[] };
|
free?: { count: number, freeData: any[] };
|
||||||
}
|
}
|
@ -18,6 +18,6 @@
|
|||||||
"include": [
|
"include": [
|
||||||
"src/**/*.ts"
|
"src/**/*.ts"
|
||||||
],
|
],
|
||||||
"exclude": ["node_modules", "dist"]
|
"exclude": ["node_modules", "dist", "release"]
|
||||||
}
|
}
|
||||||
|
|
@ -1,38 +0,0 @@
|
|||||||
import type { TsrpcConfig } from "tsrpc-cli";
|
|
||||||
|
|
||||||
export default <TsrpcConfig>{
|
|
||||||
// Generate ServiceProto
|
|
||||||
proto: [
|
|
||||||
{
|
|
||||||
ptlDir: "src/shared/protocols", // Protocol dir
|
|
||||||
output: "src/shared/protocols/serviceProto.ts", // Path for generated ServiceProto
|
|
||||||
apiDir: "src/api", // API dir
|
|
||||||
docDir: "docs", // API documents dir
|
|
||||||
ptlTemplate: { baseFile: "src/shared/protocols/base.ts" },
|
|
||||||
// msgTemplate: { baseFile: 'src/shared/protocols/base.ts' },
|
|
||||||
}
|
|
||||||
],
|
|
||||||
// Sync shared code
|
|
||||||
sync: [
|
|
||||||
{
|
|
||||||
from: "src/shared",
|
|
||||||
// to: "../GuessWhoIAm/src/shared",
|
|
||||||
type: "copy" // Change this to 'copy' if your environment not support symlink
|
|
||||||
}
|
|
||||||
],
|
|
||||||
// Dev server
|
|
||||||
dev: {
|
|
||||||
autoProto: true, // Auto regenerate proto
|
|
||||||
autoSync: true, // Auto sync when file changed
|
|
||||||
autoApi: true, // Auto create API when ServiceProto updated
|
|
||||||
watch: "src", // Restart dev server when these files changed
|
|
||||||
entry: "src/index.ts", // Dev server command: node -r ts-node/register {entry}
|
|
||||||
},
|
|
||||||
// Build config
|
|
||||||
build: {
|
|
||||||
autoProto: true, // Auto generate proto before build
|
|
||||||
autoSync: true, // Auto sync before build
|
|
||||||
autoApi: true, // Auto generate API before build
|
|
||||||
outDir: "dist", // Clean this dir before build
|
|
||||||
}
|
|
||||||
};
|
|
Loading…
Reference in New Issue
Block a user