mirror of
https://github.com/PHIDIAS0303/ExpCluster.git
synced 2025-12-27 03:25:23 +09:00
Merge branch 'explosivegaming:main' into aperx
This commit is contained in:
@@ -7,7 +7,7 @@
|
||||
"repository": "explosivegaming/ExpCluster",
|
||||
"main": "dist/node/index.js",
|
||||
"scripts": {
|
||||
"prepare": "tsc --build"
|
||||
"prepare": "tsc --build && webpack-cli --env production"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
@@ -18,7 +18,10 @@
|
||||
"devDependencies": {
|
||||
"@clusterio/lib": "catalog:",
|
||||
"@types/node": "catalog:",
|
||||
"typescript": "catalog:"
|
||||
"typescript": "catalog:",
|
||||
"webpack": "catalog:",
|
||||
"webpack-cli": "catalog:",
|
||||
"webpack-merge": "catalog:"
|
||||
},
|
||||
"dependencies": {
|
||||
"@expcluster/lib_util": "workspace:^",
|
||||
|
||||
4
exp_commands/tsconfig.browser.json
Normal file
4
exp_commands/tsconfig.browser.json
Normal file
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"extends": "../tsconfig.browser.json",
|
||||
"include": [ "web/**/*.tsx", "web/**/*.ts", "package.json" ],
|
||||
}
|
||||
@@ -1,6 +1,7 @@
|
||||
{
|
||||
"files": [],
|
||||
"references": [
|
||||
{ "path": "./tsconfig.node.json" }
|
||||
{ "path": "./tsconfig.node.json" },
|
||||
{ "path": "./tsconfig.browser.json" }
|
||||
]
|
||||
}
|
||||
|
||||
0
exp_commands/web/index.tsx
Normal file
0
exp_commands/web/index.tsx
Normal file
29
exp_commands/webpack.config.js
Normal file
29
exp_commands/webpack.config.js
Normal file
@@ -0,0 +1,29 @@
|
||||
"use strict";
|
||||
const path = require("path");
|
||||
const webpack = require("webpack");
|
||||
const { merge } = require("webpack-merge");
|
||||
|
||||
const common = require("@clusterio/web_ui/webpack.common");
|
||||
|
||||
module.exports = (env = {}) => merge(common(env), {
|
||||
context: __dirname,
|
||||
entry: "./web/index.tsx",
|
||||
output: {
|
||||
path: path.resolve(__dirname, "dist", "web"),
|
||||
},
|
||||
plugins: [
|
||||
new webpack.container.ModuleFederationPlugin({
|
||||
name: "exp_commands",
|
||||
library: { type: "window", name: "plugin_exp_commands" },
|
||||
exposes: {
|
||||
"./": "./index.ts",
|
||||
"./package.json": "./package.json",
|
||||
"./web": "./web/index.tsx",
|
||||
},
|
||||
shared: {
|
||||
"@clusterio/lib": { import: false },
|
||||
"@clusterio/web_ui": { import: false },
|
||||
},
|
||||
}),
|
||||
],
|
||||
});
|
||||
@@ -7,7 +7,7 @@
|
||||
"repository": "explosivegaming/ExpCluster",
|
||||
"main": "dist/node/index.js",
|
||||
"scripts": {
|
||||
"prepare": "tsc --build"
|
||||
"prepare": "tsc --build && webpack-cli --env production"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
@@ -18,7 +18,10 @@
|
||||
"devDependencies": {
|
||||
"@clusterio/lib": "catalog:",
|
||||
"@types/node": "catalog:",
|
||||
"typescript": "catalog:"
|
||||
"typescript": "catalog:",
|
||||
"webpack": "catalog:",
|
||||
"webpack-cli": "catalog:",
|
||||
"webpack-merge": "catalog:"
|
||||
},
|
||||
"dependencies": {
|
||||
"@expcluster/lib_util": "workspace:^",
|
||||
|
||||
4
exp_gui/tsconfig.browser.json
Normal file
4
exp_gui/tsconfig.browser.json
Normal file
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"extends": "../tsconfig.browser.json",
|
||||
"include": [ "web/**/*.tsx", "web/**/*.ts", "package.json" ],
|
||||
}
|
||||
@@ -1,6 +1,7 @@
|
||||
{
|
||||
"files": [],
|
||||
"references": [
|
||||
{ "path": "./tsconfig.node.json" }
|
||||
{ "path": "./tsconfig.node.json" },
|
||||
{ "path": "./tsconfig.browser.json" }
|
||||
]
|
||||
}
|
||||
|
||||
0
exp_gui/web/index.tsx
Normal file
0
exp_gui/web/index.tsx
Normal file
29
exp_gui/webpack.config.js
Normal file
29
exp_gui/webpack.config.js
Normal file
@@ -0,0 +1,29 @@
|
||||
"use strict";
|
||||
const path = require("path");
|
||||
const webpack = require("webpack");
|
||||
const { merge } = require("webpack-merge");
|
||||
|
||||
const common = require("@clusterio/web_ui/webpack.common");
|
||||
|
||||
module.exports = (env = {}) => merge(common(env), {
|
||||
context: __dirname,
|
||||
entry: "./web/index.tsx",
|
||||
output: {
|
||||
path: path.resolve(__dirname, "dist", "web"),
|
||||
},
|
||||
plugins: [
|
||||
new webpack.container.ModuleFederationPlugin({
|
||||
name: "exp_gui",
|
||||
library: { type: "window", name: "plugin_exp_gui" },
|
||||
exposes: {
|
||||
"./": "./index.ts",
|
||||
"./package.json": "./package.json",
|
||||
"./web": "./web/index.tsx",
|
||||
},
|
||||
shared: {
|
||||
"@clusterio/lib": { import: false },
|
||||
"@clusterio/web_ui": { import: false },
|
||||
},
|
||||
}),
|
||||
],
|
||||
});
|
||||
@@ -7,7 +7,7 @@
|
||||
"repository": "explosivegaming/ExpCluster",
|
||||
"main": "dist/node/index.js",
|
||||
"scripts": {
|
||||
"prepare": "tsc --build"
|
||||
"prepare": "tsc --build && webpack-cli --env production"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
@@ -18,7 +18,10 @@
|
||||
"devDependencies": {
|
||||
"@clusterio/lib": "catalog:",
|
||||
"@types/node": "catalog:",
|
||||
"typescript": "catalog:"
|
||||
"typescript": "catalog:",
|
||||
"webpack": "catalog:",
|
||||
"webpack-cli": "catalog:",
|
||||
"webpack-merge": "catalog:"
|
||||
},
|
||||
"dependencies": {
|
||||
"@expcluster/lib_commands": "workspace:^",
|
||||
|
||||
4
exp_legacy/tsconfig.browser.json
Normal file
4
exp_legacy/tsconfig.browser.json
Normal file
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"extends": "../tsconfig.browser.json",
|
||||
"include": [ "web/**/*.tsx", "web/**/*.ts", "package.json" ],
|
||||
}
|
||||
@@ -1,6 +1,7 @@
|
||||
{
|
||||
"files": [],
|
||||
"references": [
|
||||
{ "path": "./tsconfig.node.json" }
|
||||
{ "path": "./tsconfig.node.json" },
|
||||
{ "path": "./tsconfig.browser.json" }
|
||||
]
|
||||
}
|
||||
|
||||
0
exp_legacy/web/index.tsx
Normal file
0
exp_legacy/web/index.tsx
Normal file
29
exp_legacy/webpack.config.js
Normal file
29
exp_legacy/webpack.config.js
Normal file
@@ -0,0 +1,29 @@
|
||||
"use strict";
|
||||
const path = require("path");
|
||||
const webpack = require("webpack");
|
||||
const { merge } = require("webpack-merge");
|
||||
|
||||
const common = require("@clusterio/web_ui/webpack.common");
|
||||
|
||||
module.exports = (env = {}) => merge(common(env), {
|
||||
context: __dirname,
|
||||
entry: "./web/index.tsx",
|
||||
output: {
|
||||
path: path.resolve(__dirname, "dist", "web"),
|
||||
},
|
||||
plugins: [
|
||||
new webpack.container.ModuleFederationPlugin({
|
||||
name: "exp_legacy",
|
||||
library: { type: "window", name: "plugin_exp_legacy" },
|
||||
exposes: {
|
||||
"./": "./index.ts",
|
||||
"./package.json": "./package.json",
|
||||
"./web": "./web/index.tsx",
|
||||
},
|
||||
shared: {
|
||||
"@clusterio/lib": { import: false },
|
||||
"@clusterio/web_ui": { import: false },
|
||||
},
|
||||
}),
|
||||
],
|
||||
});
|
||||
@@ -401,6 +401,9 @@ end
|
||||
--- @param player LuaPlayer
|
||||
function Elements.container.clear_player_bonus(player)
|
||||
Elements.container.data[player] = {}
|
||||
if not player.character then
|
||||
return
|
||||
end
|
||||
for _, bonus_data in pairs(config.player_bonus) do
|
||||
if not bonus_data.is_special then
|
||||
player[bonus_data.name] = 0
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
{
|
||||
"files": [],
|
||||
"references": [
|
||||
{ "path": "./tsconfig.node.json" }
|
||||
{ "path": "./tsconfig.node.json" },
|
||||
{ "path": "./tsconfig.browser.json" }
|
||||
]
|
||||
}
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
"repository": "explosivegaming/ExpCluster",
|
||||
"main": "dist/node/index.js",
|
||||
"scripts": {
|
||||
"prepare": "tsc --build"
|
||||
"prepare": "tsc --build && webpack-cli --env production"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
@@ -18,7 +18,10 @@
|
||||
"devDependencies": {
|
||||
"@clusterio/lib": "catalog:",
|
||||
"@types/node": "catalog:",
|
||||
"typescript": "catalog:"
|
||||
"typescript": "catalog:",
|
||||
"webpack": "catalog:",
|
||||
"webpack-cli": "catalog:",
|
||||
"webpack-merge": "catalog:"
|
||||
},
|
||||
"dependencies": {
|
||||
"@sinclair/typebox": "catalog:"
|
||||
|
||||
4
exp_util/tsconfig.browser.json
Normal file
4
exp_util/tsconfig.browser.json
Normal file
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"extends": "../tsconfig.browser.json",
|
||||
"include": [ "web/**/*.tsx", "web/**/*.ts", "package.json" ],
|
||||
}
|
||||
@@ -1,6 +1,7 @@
|
||||
{
|
||||
"files": [],
|
||||
"references": [
|
||||
{ "path": "./tsconfig.node.json" }
|
||||
{ "path": "./tsconfig.node.json" },
|
||||
{ "path": "./tsconfig.browser.json" }
|
||||
]
|
||||
}
|
||||
|
||||
0
exp_util/web/index.tsx
Normal file
0
exp_util/web/index.tsx
Normal file
29
exp_util/webpack.config.js
Normal file
29
exp_util/webpack.config.js
Normal file
@@ -0,0 +1,29 @@
|
||||
"use strict";
|
||||
const path = require("path");
|
||||
const webpack = require("webpack");
|
||||
const { merge } = require("webpack-merge");
|
||||
|
||||
const common = require("@clusterio/web_ui/webpack.common");
|
||||
|
||||
module.exports = (env = {}) => merge(common(env), {
|
||||
context: __dirname,
|
||||
entry: "./web/index.tsx",
|
||||
output: {
|
||||
path: path.resolve(__dirname, "dist", "web"),
|
||||
},
|
||||
plugins: [
|
||||
new webpack.container.ModuleFederationPlugin({
|
||||
name: "exp_util",
|
||||
library: { type: "window", name: "plugin_exp_util" },
|
||||
exposes: {
|
||||
"./": "./index.ts",
|
||||
"./package.json": "./package.json",
|
||||
"./web": "./web/index.tsx",
|
||||
},
|
||||
shared: {
|
||||
"@clusterio/lib": { import: false },
|
||||
"@clusterio/web_ui": { import: false },
|
||||
},
|
||||
}),
|
||||
],
|
||||
});
|
||||
36
pnpm-lock.yaml
generated
36
pnpm-lock.yaml
generated
@@ -69,6 +69,15 @@ importers:
|
||||
typescript:
|
||||
specifier: 'catalog:'
|
||||
version: 5.8.3
|
||||
webpack:
|
||||
specifier: 'catalog:'
|
||||
version: 5.98.0(@swc/core@1.11.16)(webpack-cli@5.1.4)
|
||||
webpack-cli:
|
||||
specifier: 'catalog:'
|
||||
version: 5.1.4(webpack@5.98.0)
|
||||
webpack-merge:
|
||||
specifier: 'catalog:'
|
||||
version: 5.10.0
|
||||
|
||||
exp_groups:
|
||||
dependencies:
|
||||
@@ -134,6 +143,15 @@ importers:
|
||||
typescript:
|
||||
specifier: 'catalog:'
|
||||
version: 5.8.3
|
||||
webpack:
|
||||
specifier: 'catalog:'
|
||||
version: 5.98.0(@swc/core@1.11.16)(webpack-cli@5.1.4)
|
||||
webpack-cli:
|
||||
specifier: 'catalog:'
|
||||
version: 5.1.4(webpack@5.98.0)
|
||||
webpack-merge:
|
||||
specifier: 'catalog:'
|
||||
version: 5.10.0
|
||||
|
||||
exp_legacy:
|
||||
dependencies:
|
||||
@@ -156,6 +174,15 @@ importers:
|
||||
typescript:
|
||||
specifier: 'catalog:'
|
||||
version: 5.8.3
|
||||
webpack:
|
||||
specifier: 'catalog:'
|
||||
version: 5.98.0(@swc/core@1.11.16)(webpack-cli@5.1.4)
|
||||
webpack-cli:
|
||||
specifier: 'catalog:'
|
||||
version: 5.1.4(webpack@5.98.0)
|
||||
webpack-merge:
|
||||
specifier: 'catalog:'
|
||||
version: 5.10.0
|
||||
|
||||
exp_scenario:
|
||||
dependencies:
|
||||
@@ -252,6 +279,15 @@ importers:
|
||||
typescript:
|
||||
specifier: 'catalog:'
|
||||
version: 5.8.3
|
||||
webpack:
|
||||
specifier: 'catalog:'
|
||||
version: 5.98.0(@swc/core@1.11.16)(webpack-cli@5.1.4)
|
||||
webpack-cli:
|
||||
specifier: 'catalog:'
|
||||
version: 5.1.4(webpack@5.98.0)
|
||||
webpack-merge:
|
||||
specifier: 'catalog:'
|
||||
version: 5.10.0
|
||||
|
||||
packages:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user