修复编辑器报错的bug

This commit is contained in:
unanmed 2023-03-04 20:21:12 +08:00
parent e65b6a57aa
commit b0bfbfa0a4
8 changed files with 161 additions and 106 deletions

View File

@ -20,7 +20,7 @@
"axios": "^1.3.4",
"chart.js": "^4.2.1",
"lodash": "^4.17.21",
"lz-string": "^1.4.4",
"lz-string": "^1.5.0",
"mutate-animate": "^1.0.2",
"three": "^0.149.0",
"vue": "^3.2.47"
@ -33,7 +33,7 @@
"@types/fs-extra": "^9.0.13",
"@types/lodash": "^4.14.191",
"@types/lz-string": "^1.3.34",
"@types/node": "^18.14.1",
"@types/node": "^18.14.6",
"@vitejs/plugin-legacy": "^2.3.1",
"@vitejs/plugin-vue": "^3.2.0",
"@vitejs/plugin-vue-jsx": "^2.1.1",

View File

@ -9,7 +9,7 @@ specifiers:
'@types/fs-extra': ^9.0.13
'@types/lodash': ^4.14.191
'@types/lz-string': ^1.3.34
'@types/node': ^18.14.1
'@types/node': ^18.14.6
'@vitejs/plugin-legacy': ^2.3.1
'@vitejs/plugin-vue': ^3.2.0
'@vitejs/plugin-vue-jsx': ^2.1.1
@ -22,7 +22,7 @@ specifiers:
fs-extra: ^10.1.0
less: ^4.1.3
lodash: ^4.17.21
lz-string: ^1.4.4
lz-string: ^1.5.0
mutate-animate: ^1.0.2
terser: ^5.16.5
three: ^0.149.0
@ -39,7 +39,7 @@ dependencies:
axios: 1.3.4
chart.js: 4.2.1
lodash: 4.17.21
lz-string: 1.4.4
lz-string: 1.5.0
mutate-animate: 1.0.2
three: 0.149.0
vue: 3.2.47
@ -52,7 +52,7 @@ devDependencies:
'@types/fs-extra': 9.0.13
'@types/lodash': 4.14.191
'@types/lz-string': 1.3.34
'@types/node': 18.14.1
'@types/node': 18.14.6
'@vitejs/plugin-legacy': 2.3.1_terser@5.16.5+vite@3.2.5
'@vitejs/plugin-vue': 3.2.0_vite@3.2.5+vue@3.2.47
'@vitejs/plugin-vue-jsx': 2.1.1_vite@3.2.5+vue@3.2.47
@ -62,10 +62,10 @@ devDependencies:
fs-extra: 10.1.0
less: 4.1.3
terser: 5.16.5
ts-node: 10.9.1_uayvamxqnl5yeiojjysxwopmsy
ts-node: 10.9.1_alpjt73dvgv6kni625hu7f2l4m
typescript: 4.9.5
unplugin-vue-components: 0.22.12_vue@3.2.47
vite: 3.2.5_26teffiwv23ewycaezkrzbl33m
vite: 3.2.5_vqdxw55p6u6allcygj7vgnsdna
vue-tsc: 1.2.0_typescript@4.9.5
packages:
@ -1460,7 +1460,7 @@ packages:
/@simonwep/pickr/1.8.2:
resolution: {integrity: sha512-/l5w8BIkrpP6n1xsetx9MWPWlU6OblN5YgZZphxan0Tq4BByTCETL6lyIeY8lagalS2Nbt4F2W034KHLIiunKA==}
dependencies:
core-js: 3.28.0
core-js: 3.29.0
nanopop: 2.2.0
dev: false
@ -1492,13 +1492,13 @@ packages:
/@types/fontmin/0.9.0:
resolution: {integrity: sha512-nWUcpO53EPPKUnkcQJRYyEbiojO/WXHFHOuo6GHWptaoVhFg036eB9z0OoecnhPj/1TWue0Ls5TlqSJLbRJRvg==}
dependencies:
'@types/node': 18.14.1
'@types/node': 18.14.6
dev: true
/@types/fs-extra/9.0.13:
resolution: {integrity: sha512-nEnwB++1u5lVDM2UI4c1+5R+FYaKfaAzS4OococimjVm3nQw3TuzH5UNsocrcTBbhnerblyHj4A49qXbIiZdpA==}
dependencies:
'@types/node': 18.14.1
'@types/node': 18.14.6
dev: true
/@types/lodash/4.14.191:
@ -1513,8 +1513,8 @@ packages:
resolution: {integrity: sha512-jhuKLIRrhvCPLqwPcx6INqmKeiA5EWrsCOPhrlFSrbrmU4ZMPjj5Ul/oLCMDO98XRUIwVm78xICz4EPCektzeQ==}
dev: true
/@types/node/18.14.1:
resolution: {integrity: sha512-QH+37Qds3E0eDlReeboBxfHbX9omAcBCXEzswCu6jySP642jiM3cYSIkU/REqwhCUqXdonHFuBfJDiAJxMNhaQ==}
/@types/node/18.14.6:
resolution: {integrity: sha512-93+VvleD3mXwlLI/xASjw0FzKcwzl3OdTCzm1LaRfqgS21gfFtK3zDXM5Op9TeeMsJVOaJ2VRDpT9q4Y3d0AvA==}
dev: true
/@types/normalize-package-data/2.4.1:
@ -1529,12 +1529,12 @@ packages:
vite: ^3.0.0
dependencies:
'@babel/standalone': 7.21.2
core-js: 3.28.0
core-js: 3.29.0
magic-string: 0.26.7
regenerator-runtime: 0.13.11
systemjs: 6.14.0
terser: 5.16.5
vite: 3.2.5_26teffiwv23ewycaezkrzbl33m
vite: 3.2.5_vqdxw55p6u6allcygj7vgnsdna
dev: true
/@vitejs/plugin-vue-jsx/2.1.1_vite@3.2.5+vue@3.2.47:
@ -1547,7 +1547,7 @@ packages:
'@babel/core': 7.21.0
'@babel/plugin-transform-typescript': 7.21.0_@babel+core@7.21.0
'@vue/babel-plugin-jsx': 1.1.1_@babel+core@7.21.0
vite: 3.2.5_26teffiwv23ewycaezkrzbl33m
vite: 3.2.5_vqdxw55p6u6allcygj7vgnsdna
vue: 3.2.47
transitivePeerDependencies:
- supports-color
@ -1560,7 +1560,7 @@ packages:
vite: ^3.0.0
vue: ^3.2.25
dependencies:
vite: 3.2.5_26teffiwv23ewycaezkrzbl33m
vite: 3.2.5_vqdxw55p6u6allcygj7vgnsdna
vue: 3.2.47
dev: true
@ -1927,8 +1927,8 @@ packages:
engines: {node: ^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7}
hasBin: true
dependencies:
caniuse-lite: 1.0.30001458
electron-to-chromium: 1.4.311
caniuse-lite: 1.0.30001460
electron-to-chromium: 1.4.320
node-releases: 2.0.10
update-browserslist-db: 1.0.10_browserslist@4.21.5
dev: true
@ -1988,7 +1988,7 @@ packages:
fs-minipass: 2.1.0
glob: 8.1.0
infer-owner: 1.0.4
lru-cache: 7.17.0
lru-cache: 7.18.1
minipass: 3.3.6
minipass-collect: 1.0.2
minipass-flush: 1.0.5
@ -2026,8 +2026,8 @@ packages:
engines: {node: '>=10'}
dev: true
/caniuse-lite/1.0.30001458:
resolution: {integrity: sha512-lQ1VlUUq5q9ro9X+5gOEyH7i3vm+AYVT1WDCVB69XOZ17KZRhnZ9J0Sqz7wTHQaLBJccNCHq8/Ww5LlOIZbB0w==}
/caniuse-lite/1.0.30001460:
resolution: {integrity: sha512-Bud7abqjvEjipUkpLs4D7gR0l8hBYBHoa+tGtKJHvT2AYzLp1z7EmVkUT4ERpVUfca8S2HGIVs883D8pUH1ZzQ==}
dev: true
/chalk/2.4.2:
@ -2195,8 +2195,8 @@ packages:
browserslist: 4.21.5
dev: true
/core-js/3.28.0:
resolution: {integrity: sha512-GiZn9D4Z/rSYvTeg1ljAIsEqFm0LaN9gVtwDCrKL80zHtS31p9BAjmTxVqTQDMpwlMolJZOFntUG2uwyj7DAqw==}
/core-js/3.29.0:
resolution: {integrity: sha512-VG23vuEisJNkGl6XQmFJd3rEG/so/CNatqeE+7uZAwTSwFeB/qaO0be8xZYUNWprJ/GIwL8aMt9cj1kvbpTZhg==}
requiresBuild: true
/core-util-is/1.0.3:
@ -2307,8 +2307,8 @@ packages:
stream-shift: 1.0.1
dev: true
/electron-to-chromium/1.4.311:
resolution: {integrity: sha512-RoDlZufvrtr2Nx3Yx5MB8jX3aHIxm8nRWPJm3yVvyHmyKaRvn90RjzB6hNnt0AkhS3IInJdyRfQb4mWhPvUjVw==}
/electron-to-chromium/1.4.320:
resolution: {integrity: sha512-h70iRscrNluMZPVICXYl5SSB+rBKo22XfuIS1ER0OQxQZpKTnFpuS6coj7wY9M/3trv7OR88rRMOlKmRvDty7Q==}
dev: true
/emoji-regex/8.0.0:
@ -2596,8 +2596,8 @@ packages:
micromatch: 4.0.5
dev: true
/fast-xml-parser/3.21.1:
resolution: {integrity: sha512-FTFVjYoBOZTJekiUsawGsSYV9QL0A+zDYCRj7y34IO6Jg+2IMYEtQa+bbictpdpV8dHxXywqU7C0gRDEOFtBFg==}
/fast-xml-parser/4.1.3:
resolution: {integrity: sha512-LsNDahCiCcJPe8NO7HijcnukHB24tKbfDDA5IILx9dmW3Frb52lhbeX6MPNUSvyGNfav2VTYpJ/OqkRoVLrh2Q==}
hasBin: true
dependencies:
strnum: 1.0.5
@ -2678,7 +2678,7 @@ packages:
fonteditor-core: 2.1.11
get-stdin: 9.0.0
is-otf: 0.1.2
is-svg: 4.3.2
is-svg: 4.4.0
is-ttf: 0.2.2
lodash: 4.17.21
meow: 10.1.5
@ -3074,11 +3074,11 @@ packages:
is-unc-path: 1.0.0
dev: true
/is-svg/4.3.2:
resolution: {integrity: sha512-mM90duy00JGMyjqIVHu9gNTjywdZV+8qNasX8cm/EEYZ53PHDgajvbBwNVvty5dwSAxLUD3p3bdo+7sR/UMrpw==}
/is-svg/4.4.0:
resolution: {integrity: sha512-v+AgVwiK5DsGtT9ng+m4mClp6zDAmwrW8nZi6Gg15qzvBnRWWdfWA1TGaXyCDnWq5g5asofIgMVl3PjKxvk1ug==}
engines: {node: '>=6'}
dependencies:
fast-xml-parser: 3.21.1
fast-xml-parser: 4.1.3
dev: true
/is-ttf/0.2.2:
@ -3243,13 +3243,13 @@ packages:
yallist: 4.0.0
dev: true
/lru-cache/7.17.0:
resolution: {integrity: sha512-zSxlVVwOabhVyTi6E8gYv2cr6bXK+8ifYz5/uyJb9feXX6NACVDwY4p5Ut3WC3Ivo/QhpARHU3iujx2xGAYHbQ==}
/lru-cache/7.18.1:
resolution: {integrity: sha512-8/HcIENyQnfUTCDizRu9rrDyG6XG/21M4X7/YEGZeD76ZJilFPAUVb/2zysFf7VVO1LEjCDFyHp8pMMvozIrvg==}
engines: {node: '>=12'}
dev: true
/lz-string/1.4.4:
resolution: {integrity: sha512-0ckx7ZHRPqb0oUm8zNr+90mtf9DQB60H1wMCjBtfi62Kl3a7JbHob6gA2bC+xRvZoOL+1hzUK8jeuEIQE8svEQ==}
/lz-string/1.5.0:
resolution: {integrity: sha512-h5bgJWpxJNswbU7qCrV0tIKQCaS3blPDrqKWx+QxzuzL1zGUzij9XCWLrSLsJPu5t+eWA/ycetzYAO5IOMcWAQ==}
hasBin: true
dev: false
@ -3295,7 +3295,7 @@ packages:
http-proxy-agent: 5.0.0
https-proxy-agent: 5.0.1
is-lambda: 1.0.1
lru-cache: 7.17.0
lru-cache: 7.18.1
minipass: 3.3.6
minipass-collect: 1.0.2
minipass-fetch: 2.1.2
@ -3453,8 +3453,8 @@ packages:
yallist: 4.0.0
dev: true
/minipass/4.2.1:
resolution: {integrity: sha512-KS4CHIsDfOZetnT+u6fwxyFADXLamtkPxkGScmmtTW//MlRrImV+LtbmbJpLQ86Hw7km/utbfEfndhGBrfwvlA==}
/minipass/4.2.4:
resolution: {integrity: sha512-lwycX3cBMTvcejsHITUgYj6Gy6A7Nh4Q6h9NP4sTHY1ccJlC7yKzDmiShEHsJ16Jf1nKGDEaiHxiltsJEvk0nQ==}
engines: {node: '>=8'}
dev: true
@ -4174,7 +4174,7 @@ packages:
dependencies:
chownr: 2.0.0
fs-minipass: 2.1.0
minipass: 4.2.1
minipass: 4.2.4
minizlib: 2.1.2
mkdirp: 1.0.4
yallist: 4.0.0
@ -4254,7 +4254,7 @@ packages:
engines: {node: '>=12'}
dev: true
/ts-node/10.9.1_uayvamxqnl5yeiojjysxwopmsy:
/ts-node/10.9.1_alpjt73dvgv6kni625hu7f2l4m:
resolution: {integrity: sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw==}
hasBin: true
peerDependencies:
@ -4273,7 +4273,7 @@ packages:
'@tsconfig/node12': 1.0.11
'@tsconfig/node14': 1.0.3
'@tsconfig/node16': 1.0.3
'@types/node': 18.14.1
'@types/node': 18.14.6
acorn: 8.8.2
acorn-walk: 8.2.0
arg: 4.1.3
@ -4501,7 +4501,7 @@ packages:
replace-ext: 1.0.1
dev: true
/vite/3.2.5_26teffiwv23ewycaezkrzbl33m:
/vite/3.2.5_vqdxw55p6u6allcygj7vgnsdna:
resolution: {integrity: sha512-4mVEpXpSOgrssFZAOmGIr85wPHKvaDAcXqxVxVRZhljkJOMZi1ibLibzjLHzJvcok8BMguLc7g1W6W/GqZbLdQ==}
engines: {node: ^14.18.0 || >=16.0.0}
hasBin: true
@ -4526,7 +4526,7 @@ packages:
terser:
optional: true
dependencies:
'@types/node': 18.14.1
'@types/node': 18.14.6
esbuild: 0.15.18
less: 4.1.3
postcss: 8.4.21

View File

@ -280,12 +280,14 @@ function core() {
/////////// 系统事件相关 ///////////
////// 初始化 //////
core.prototype.init = function (coreData, callback) {
core.prototype.init = async function (coreData, callback) {
this._forwardFuncs();
for (var key in coreData) core[key] = coreData[key];
this._init_flags();
this._init_platform();
this._init_others();
await this._loadPlugin();
var b = main.mode == 'editor';
// 初始化画布
for (var name in core.canvas) {
@ -308,6 +310,26 @@ core.prototype.init = function (coreData, callback) {
});
};
core.prototype._loadPlugin = async function () {
const mainData = data_a1e2fb4a_e986_4524_b0da_9b7ba7c0874d.main;
core.plugin = {};
// 加载插件
if (!main.replayChecking && main.mode === 'play') {
main.forward();
core.resetSettings();
core.plugin.showMarkedEnemy.value = true;
}
if (main.pluginUseCompress) {
await main.loadScript(`project/plugin.min.js?v=${main.version}`);
} else {
for await (const plugin of mainData.plugin) {
await main.loadScript(
`project/plugin/${plugin}.js?v=${main.version}`
);
}
}
};
core.prototype._init_flags = function () {
core.flags = core.clone(core.data.flags);
core.values = core.clone(core.data.values);

View File

@ -237,6 +237,7 @@ main.prototype.init = async function (mode, callback) {
eval('`${123}`');
} catch {
alert('浏览器版本过低,无法游玩本塔!');
alert('建议使用Edge浏览器或Chrome浏览器游玩');
return;
}
@ -323,23 +324,6 @@ main.prototype.init = async function (mode, callback) {
main.core = core;
core.plugin = {};
// 加载插件
if (!main.replayChecking && main.mode === 'play') {
main.forward();
core.resetSettings();
core.plugin.showMarkedEnemy.value = true;
}
if (main.pluginUseCompress) {
await main.loadScript(`project/plugin.min.js?v=${main.version}`);
} else {
for await (const plugin of mainData.plugin) {
await main.loadScript(
`project/plugin/${plugin}.js?v=${main.version}`
);
}
}
// 自动放缩最大化
const auto = core.getLocalStorage('autoScale');
if (auto == null) {

Binary file not shown.

View File

@ -1,39 +1,39 @@
var enemys_fcae963b_31c9_42b4_b48c_bb48d09f3f80 =
{
"greenSlime": {"name":"绿头怪","hp":100,"atk":11,"def":3,"money":0,"exp":1,"point":0,"special":[],"description":"一种极其低级的怪物,低级到普通人用手都可以打死。"},
"redSlime": {"name":"红头怪","hp":120,"atk":16,"def":6,"money":0,"exp":2,"point":0,"special":[],"value":10,"description":"即使是最弱的怪物,也有进化的时候,对吧?"},
"blackSlime": {"name":"青头怪","hp":170,"atk":20,"def":8,"money":0,"exp":3,"point":0,"special":[],"description":"看,这就是最弱的怪物进化出的最强的怪物之一了"},
"slimelord": {"name":"粘液王","hp":200,"atk":58,"def":24,"money":0,"exp":8,"point":0,"special":[],"description":"看上去黏糊糊的,实际也确实黏糊糊的,据说是史莱姆族的长老级人物"},
"greenSlime": {"name":"绿头怪","hp":100,"atk":11,"def":3,"money":0,"exp":1,"point":0,"special":[],"description":"别小看这些家伙,虽然他们只是一种极其低级的怪物,低级到普通人用手都可以打死,但数量是他们的优势。"},
"redSlime": {"name":"红头怪","hp":120,"atk":16,"def":6,"money":0,"exp":2,"point":0,"special":[],"value":10,"description":"即使是最弱的怪物,也有进化的时候,对吧?据说,红头怪便是绿头怪进化形成的。"},
"blackSlime": {"name":"青头怪","hp":170,"atk":20,"def":8,"money":0,"exp":3,"point":0,"special":[],"description":"看,这就是最弱的怪物进化出的最强的怪物之一了。他们弱吗?"},
"slimelord": {"name":"粘液王","hp":200,"atk":58,"def":24,"money":0,"exp":8,"point":0,"special":[],"description":"看上去黏糊糊的,实际也确实黏糊糊的,据说是史莱姆族的长老级人物,拥有不俗的实力。"},
"bat": {"name":"小蝙蝠","hp":60,"atk":15,"def":0,"money":0,"exp":2,"point":0,"special":[4],"description":"经常出现在山洞中,再平常不过了。但是这次它却有了攻击性。"},
"bigBat": {"name":"大蝙蝠","hp":150,"atk":17,"def":5,"money":0,"exp":4,"point":0,"special":[4],"crit":0,"charge":0,"courage":0,"together":0,"hungry":0,"value":100,"n":1000},
"redBat": {"name":"恐怖蝙蝠","hp":1200,"atk":260,"def":110,"money":1,"exp":32,"point":0,"special":[5]},
"bigBat": {"name":"大蝙蝠","hp":150,"atk":17,"def":5,"money":0,"exp":4,"point":0,"special":[4],"crit":0,"charge":0,"courage":0,"together":0,"hungry":0,"value":100,"n":1000,"description":"或许是小蝙蝠的父亲?一种极其强悍的蝙蝠,实力不够千万不要靠近他。"},
"redBat": {"name":"恐怖蝙蝠","hp":1200,"atk":260,"def":110,"money":1,"exp":32,"point":0,"special":[5],"description":"恐惧?或许他们并不知道恐惧是什么,他们不会害怕任何东西,即使这个东西能够威胁到自己的生命。"},
"vampire": {"name":"冥灵魔王","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"skeleton": {"name":"骷髅人","hp":300,"atk":80,"def":10,"money":0,"exp":9,"point":0,"special":[1],"crit":300},
"skeletonCaptain": {"name":"骷髅队长","hp":750,"atk":200,"def":50,"money":0,"exp":21,"point":0,"special":[1],"crit":1000},
"zombie": {"name":"兽人","hp":150,"atk":43,"def":14,"money":0,"exp":6,"point":0,"special":[]},
"zombieKnight": {"name":"兽人武士","hp":480,"atk":62,"def":30,"money":0,"exp":15,"point":0,"special":[]},
"rock": {"name":"洞穴巨石","hp":31,"atk":25,"def":0,"money":0,"exp":4,"point":0,"special":[3]},
"skeleton": {"name":"骷髅人","hp":300,"atk":80,"def":10,"money":0,"exp":9,"point":0,"special":[1],"crit":300,"description":"骷髅?看起来是被人动了手脚,或许是未来的高科技机器人呢?"},
"skeletonCaptain": {"name":"骷髅队长","hp":750,"atk":200,"def":50,"money":0,"exp":21,"point":0,"special":[1],"crit":1000,"description":"机器人也会有领袖吗?这还真是第一次听说。"},
"zombie": {"name":"兽人","hp":150,"atk":43,"def":14,"money":0,"exp":6,"point":0,"special":[],"description":"野兽嘛,在远古时期,再正常不过了。"},
"zombieKnight": {"name":"兽人武士","hp":480,"atk":62,"def":30,"money":0,"exp":15,"point":0,"special":[],"description":"他们总是认为,要变得强大,杀掉其他野兽,自己才能存活下来。"},
"rock": {"name":"洞穴巨石","hp":31,"atk":25,"def":0,"money":0,"exp":4,"point":0,"special":[3],"description":"一些具有攻击性的巨石?或许就是兽人穿上了一层石头外衣吧。"},
"bluePriest": {"name":"初级法师","hp":100,"atk":120,"def":0,"money":3,"exp":0,"point":1,"special":[2]},
"redPriest": {"name":"高级法师","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"brownWizard": {"name":"初级巫师","hp":100,"atk":120,"def":0,"money":16,"exp":0,"point":0,"special":[15],"value":100,"range":2},
"redWizard": {"name":"高级巫师","hp":1000,"atk":1200,"def":0,"money":160,"exp":0,"point":0,"special":[15],"value":200,"zoneSquare":true},
"swordsman": {"name":"野蛮剑士","hp":250,"atk":55,"def":27,"money":0,"exp":9,"point":0,"special":[15],"value":75},
"swordsman": {"name":"野蛮剑士","hp":250,"atk":55,"def":27,"money":0,"exp":9,"point":0,"special":[15],"value":75,"description":"剑?这是什么东西?他们拿的只是比较锋利的骨头吧。"},
"soldier": {"name":"冥战士","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"yellowKnight": {"name":"勇气骑士","hp":2000,"atk":500,"def":250,"money":1,"exp":30,"point":0,"special":[11],"charge":500},
"yellowKnight": {"name":"勇气骑士","hp":2000,"atk":500,"def":250,"money":1,"exp":30,"point":0,"special":[11],"charge":500,"description":"人们总是说,战斗,需要的就是勇气。而骑士,或许就站在了这勇气之巅了吧。有什么用呢?战场上,该死的时候就是得死,哪怕是在这远古时期,即使不是战场,一场战斗也足以决定生死。"},
"redKnight": {"name":"红骑士","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"darkKnight": {"name":"黑骑士","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"blueKnight": {"name":"蓝骑士","hp":100,"atk":120,"def":0,"money":9,"exp":0,"point":0,"special":[8]},
"goldSlime": {"name":"黄头怪","hp":1000,"atk":50,"def":50,"money":0,"exp":18,"point":0,"special":[2]},
"poisonSkeleton": {"name":"紫骷髅","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"poisonBat": {"name":"山间蝙蝠","hp":800,"atk":170,"def":50,"money":1,"exp":24,"point":0,"special":[5]},
"skeletonPriest": {"name":"智慧骷髅","hp":4000,"atk":1200,"def":900,"money":1,"exp":75,"point":0,"special":[1,13],"value":20,"crit":500},
"poisonBat": {"name":"山间蝙蝠","hp":800,"atk":170,"def":50,"money":1,"exp":24,"point":0,"special":[5],"description":"山的高出,总会有一些恐怖的东西,就比如这只蝙蝠。"},
"skeletonPriest": {"name":"智慧骷髅","hp":4000,"atk":1200,"def":900,"money":1,"exp":75,"point":0,"special":[1,13],"value":20,"crit":500,"description":"人们说智慧可以做到任何事情,而这只骷髅却将可以变为了很容易。“我挥一挥法杖,智慧便会如泉般涌来。”,他说。"},
"skeletonKing": {"name":"骷髅王","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"evilHero": {"name":"迷失勇者","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"demonPriest": {"name":"魔神法师","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"goldHornSlime": {"name":"尖角怪","hp":1500,"atk":366,"def":166,"money":1,"exp":35,"point":0,"special":[]},
"goldHornSlime": {"name":"尖角怪","hp":1500,"atk":366,"def":166,"money":1,"exp":35,"point":0,"special":[],"description":"一个奇怪的物种,长着两只角就了不起了吗?或许还真是!"},
"silverSlime": {"name":"银头怪","hp":250,"atk":50,"def":20,"money":0,"exp":11,"point":0,"special":[2]},
"whiteHornSlime": {"name":"恐怖尖角怪","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"redSwordsman": {"name":"山间盗贼","hp":1000,"atk":175,"def":40,"money":1,"exp":24,"point":0,"special":[4],"n":8},
"redSwordsman": {"name":"山间盗贼","hp":1000,"atk":175,"def":40,"money":1,"exp":24,"point":0,"special":[4],"n":8,"description":"即使是现代法治社会,也总会有人去抢夺别人的东西,更何况远古时期呢?"},
"poisonZombie": {"name":"绿兽人","hp":100,"atk":120,"def":0,"money":13,"exp":0,"point":0,"special":[12]},
"octopus": {"name":"血影","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"princessEnemy": {"name":"假公主","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
@ -44,36 +44,36 @@ var enemys_fcae963b_31c9_42b4_b48c_bb48d09f3f80 =
"frozenSkeleton": {"name":"冻死骨","hp":7500,"atk":2500,"def":1000,"money":2,"exp":90,"point":0,"special":[1,20],"crit":500,"ice":10},
"silverSlimelord": {"name":"银怪王","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"goldSlimelord": {"name":"金怪王","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"skeletonWarrior": {"name":"骷髅士兵","hp":500,"atk":100,"def":20,"money":0,"exp":12,"point":0,"special":[1],"crit":500},
"whiteSlimeman": {"name":"水银史莱姆人","hp":750,"atk":100,"def":45,"money":0,"exp":20,"point":0,"special":[4]},
"slimeman": {"name":"莱姆人","hp":125,"atk":30,"def":10,"money":0,"exp":4,"point":0,"special":[4],"atkValue":2,"defValue":3},
"yellowGateKeeper": {"name":"神秘卫兵","hp":375,"atk":200,"def":15,"money":1,"exp":25,"point":0,"special":[1],"crit":5000},
"blueGateKeeper": {"name":"神秘雕像","hp":1000,"atk":275,"def":120,"money":1,"exp":38,"point":0,"special":[1],"crit":1000},
"redGateKeeper": {"name":"勇气卫兵","hp":1000,"atk":450,"def":250,"money":1,"exp":30,"point":0,"special":[1],"crit":2000},
"skeletonWarrior": {"name":"骷髅士兵","hp":500,"atk":100,"def":20,"money":0,"exp":12,"point":0,"special":[1],"crit":500,"description":"看来未来的机器人并不满足与赤手空拳,他们也拿上了武器。"},
"whiteSlimeman": {"name":"水银史莱姆人","hp":750,"atk":100,"def":45,"money":0,"exp":20,"point":0,"special":[4],"description":"汞?这听起来不像是一个远古时期应该存在的名字,但是把它拆分开,叫做水银,是不是可爱了一些?"},
"slimeman": {"name":"莱姆人","hp":125,"atk":30,"def":10,"money":0,"exp":4,"point":0,"special":[4],"atkValue":2,"defValue":3,"description":"又有谁不能保证史莱姆也能进化成人型生物呢?"},
"yellowGateKeeper": {"name":"神秘卫兵","hp":375,"atk":200,"def":15,"money":1,"exp":25,"point":0,"special":[1],"crit":5000,"description":"神秘卫兵。确实很神秘,他们从不说话,只知道看着你,当你攻击他们的时候,他们会给你致命的反击。"},
"blueGateKeeper": {"name":"神秘雕像","hp":1000,"atk":275,"def":120,"money":1,"exp":38,"point":0,"special":[1],"crit":1000,"description":"大概,或许,跟神秘卫兵是同一类东西?"},
"redGateKeeper": {"name":"勇气卫兵","hp":1000,"atk":450,"def":250,"money":1,"exp":30,"point":0,"special":[1],"crit":2000,"description":"没有人知道这些卫兵是什么。他们有红通通的外表,一颗怀揣着勇气的心。但是,勇气这东西,并不是越多越好,为什么?跟他打一架,他的下场便是勇气过多的下场。"},
"magicMaster": {"name":"黑暗大法师","hp":100,"atk":120,"def":0,"money":12,"exp":0,"point":0,"special":[11],"value":0.3333333333333333,"add":true,"notBomb":true},
"devilWarrior": {"name":"魔神武士","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"fairyEnemy": {"name":"仙子","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"dragon": {"name":"魔龙","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"skeletonKnight": {"name":"骷髅武士","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"skeletonPresbyter": {"name":"骷髅巫师","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"ironRock": {"name":"山间巨石","hp":750,"atk":150,"def":0,"money":0,"exp":20,"point":0,"special":[3]},
"grayRock": {"name":"林间巨石","hp":100,"atk":60,"def":0,"money":0,"exp":12,"point":0,"special":[3]},
"skeletonPresbyter": {"name":"骷髅巫师","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[],"description":"法杖,人们总觉得这种东西只应该出现在虚拟的世界中。可是,智慧却成功将这件事变为了现实,而产物便是这只骷髅巫师。"},
"ironRock": {"name":"山间巨石","hp":750,"atk":150,"def":0,"money":0,"exp":20,"point":0,"special":[3],"description":"恐怖的东西,除了那只蝙蝠,还有...这个巨石。"},
"grayRock": {"name":"林间巨石","hp":100,"atk":60,"def":0,"money":0,"exp":12,"point":0,"special":[3],"description":"貌似比山洞里面的那些家伙硬了一些?哼,那又能有什么用呢?"},
"yellowPriest": {"name":"中级法师","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"evilPrincess": {"name":"痛苦魔女","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"blademaster": {"name":"剑圣","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"evilFairy": {"name":"黑暗仙子","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"blueRock": {"name":"勇气之石","hp":2000,"atk":450,"def":230,"money":1,"exp":30,"point":0,"special":[]},
"skeletonLite": {"name":"骷髅精英","hp":2000,"atk":275,"def":240,"money":1,"exp":35,"point":0,"special":[9]},
"blueRock": {"name":"勇气之石","hp":2000,"atk":450,"def":230,"money":1,"exp":30,"point":0,"special":[],"description":"巨石,这本身是一种不可怕的怪物。而可怕的是,当这些巨石拥有了勇气,或许就很少有人敢于直面他们了。"},
"skeletonLite": {"name":"骷髅精英","hp":2000,"atk":275,"def":240,"money":1,"exp":35,"point":0,"special":[9],"description":"骷髅们总是说,没有防御力,让我怎么去攻击别人?呵,这防御力不就来了吗?可是,这又有何用呢?"},
"greenKnight": {"name":"强盾骑士","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"bowman": {"name":"猎人","hp":500,"atk":100,"def":50,"money":0,"exp":16,"point":0,"special":[24],"value":75},
"liteBowman": {"name":"山间猎手","hp":1200,"atk":200,"def":60,"money":1,"exp":27,"point":0,"special":[24]},
"crimsonZombie": {"name":"勇气之兽","hp":1800,"atk":2000,"def":-100,"money":1,"exp":35,"point":0,"special":[]},
"bowman": {"name":"猎人","hp":500,"atk":100,"def":50,"money":0,"exp":16,"point":0,"special":[24],"value":75,"description":"没人知道这些人怎么做出的弓,也没人知道他们怎么收集的这么多剑。而其他人唯一能做的事,便是远离他们。"},
"liteBowman": {"name":"山间猎手","hp":1200,"atk":200,"def":60,"money":1,"exp":27,"point":0,"special":[24],"description":"这箭,或许就是那些败于他弓下的那些不知好歹的莽夫的骨头吧。或许,绕开他的视野才是躲避他的攻击的最好办法。"},
"crimsonZombie": {"name":"勇气之兽","hp":1800,"atk":2000,"def":-100,"money":1,"exp":35,"point":0,"special":[],"description":"没人会愿意跟这些野兽一起吧?至少我是不想。上天赋予的勇气,却让他们更加渴望鲜血,这不是很可悲吗?"},
"watcherSlime": {"name":"邪眼史莱姆","hp":5000,"atk":1200,"def":600,"money":1,"exp":50,"point":0,"special":[17]},
"mutantSlimeman": {"name":"变异史莱姆人","hp":350,"atk":70,"def":27,"money":0,"exp":13,"point":0,"special":[]},
"devilKnight": {"name":"恶灵骑士","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},
"grayPriest": {"name":"智慧法王","hp":3000,"atk":600,"def":250,"money":1,"exp":40,"point":0,"special":[13]},
"greenGateKeeper": {"name":"睿智雕像","hp":5000,"atk":1250,"def":900,"money":1,"exp":65,"point":0,"special":[1],"crit":1000},
"ghostSoldier": {"name":"山间骷髅","hp":750,"atk":180,"def":40,"money":0,"exp":18,"point":0,"special":[]},
"ghostSoldier": {"name":"山间骷髅","hp":750,"atk":180,"def":40,"money":0,"exp":18,"point":0,"special":[],"description":"这次,他们穿上了盔甲。"},
"frostBat": {"name":"寒霜蝙蝠","hp":20000,"atk":3200,"def":2000,"money":2,"exp":2000,"point":0,"special":[4,20],"ice":90},
"blackKing": {"name":"黑衣魔王","hp":1000,"atk":500,"def":0,"money":1000,"exp":1000,"point":0,"special":[],"notBomb":true},
"yellowKing": {"name":"黄衣魔王","hp":0,"atk":0,"def":0,"money":0,"exp":0,"point":0,"special":[]},

View File

@ -1,9 +1,54 @@
[
{
{
"title.mp3": {
"area": "标题",
"name": "川井宪次 - 破裂足音",
"from": "《永远的七日之都》",
"img": "/project/images/bg.jpg",
"desc": []
},
"cave.mp3": {
"area": "山洞",
"name": "Faodail - Wren",
"img": "",
"desc": []
},
"grass.mp3": {
"area": "草地",
"name": "大树 & 朱晨阳 - 大树与鹿",
"img": "",
"desc": []
},
"mount.mp3": {
"area": "山路",
"name": "Epistra - Dream Of A Dream",
"img": "",
"desc": []
},
"escape.mp3": {
"area": "山路追逐",
"name": "Gareth Coker - Escaping a Foul Presence",
"from": "《奥日与精灵意志》",
"img": "",
"desc": []
},
"plot1.mp3": {
"area": "勇气之路",
"name": "Mark Petrie & Danny McCarthy - Rags To Rings",
"img": "",
"desc": []
},
"tower.mp3": {
"area": "智慧之塔",
"name": "Falcom Sound Team J.D.K. - A Light Illuminating The Depth",
"from": "《英雄传说:零之轨迹》",
"img": "",
"desc": []
},
"beforeBoss.mp3": {
"area": "战前独白",
"name": "Evan LE NY - Some Calm",
"from": "《太空化学》",
"img": "",
"desc": []
}
]
}

View File

@ -6,20 +6,20 @@
v-for="(bgm, i) of list"
class="selectable"
:selected="selected === i"
@click="selected = i"
@click="select(i)"
>
{{ bgm.area }}
{{ bgm!.area }}
</span>
</div></template
>
<template #right
><div>
<div id="bgm-name">
<img id="bgm-image" :src="list[selected].img" />
<img id="bgm-image" :src="list[selected]!.img" />
<span>{{ name }}</span>
<span v-if="list[selected].from"
<span v-if="list[selected]!.from"
>出自&nbsp;&nbsp;&nbsp;&nbsp;{{
list[selected].from
list[selected]!.from
}}</span
>
</div>
@ -41,18 +41,22 @@ interface Bgm {
from?: string;
}
const list = bgm as Bgm[];
const list = bgm as Partial<Record<BgmIds, Bgm>>;
const selected = ref(0);
const selected = ref<BgmIds>('title.mp3');
const content = computed(() => {
return eval('`' + splitText(list[selected.value].desc) + '`');
return eval('`' + splitText(list[selected.value]!.desc) + '`');
});
const name = computed(() => list[selected.value].name);
const name = computed(() => list[selected.value]!.name);
function exit() {
core.plugin.bgmOpened.value = false;
}
function select(id: BgmIds) {
selected.value = id;
}
</script>
<style lang="less" scoped>