mirror of
https://github.com/unanmed/HumanBreak.git
synced 2025-01-18 20:09:27 +08:00
完善部分ui,修改部分剧情
This commit is contained in:
parent
3db34ffad9
commit
ce838e0225
@ -15,7 +15,7 @@
|
||||
<meta name="x5-orientation" content="portrait">
|
||||
<meta name="x5-fullscreen" content="true">
|
||||
<meta name="x5-page-mode" content="app">
|
||||
<link type='text/css' href='/styles.css' rel='stylesheet'>
|
||||
<link id="mota-css" type='text/css' href='/styles.css' rel='stylesheet'>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
@ -237,6 +237,7 @@ main.prototype.init = function (mode, callback) {
|
||||
var span = document.createElement('span');
|
||||
span.setAttribute('class', 'startButton');
|
||||
span.innerText = value.title || '';
|
||||
span.id = value.name;
|
||||
(function (span, str_) {
|
||||
span.onclick = function () {
|
||||
core.events.startGame(str_);
|
||||
|
@ -199,7 +199,7 @@ var data_a1e2fb4a_e986_4524_b0da_9b7ba7c0874d =
|
||||
"levelChoose": [
|
||||
{
|
||||
"title": "简单",
|
||||
"name": "Easy",
|
||||
"name": "easy",
|
||||
"hard": 1,
|
||||
"color": [
|
||||
0,
|
||||
@ -440,41 +440,11 @@ var data_a1e2fb4a_e986_4524_b0da_9b7ba7c0874d =
|
||||
}
|
||||
],
|
||||
"startText": [
|
||||
{
|
||||
"type": "setValue",
|
||||
"name": "flag:usePlatFly",
|
||||
"value": "true"
|
||||
},
|
||||
{
|
||||
"type": "setValue",
|
||||
"name": "flag:__useMinimap__",
|
||||
"value": "true"
|
||||
},
|
||||
{
|
||||
"type": "setValue",
|
||||
"name": "flag:fixToBook",
|
||||
"value": "false"
|
||||
},
|
||||
{
|
||||
"type": "setValue",
|
||||
"name": "flag:itemDetail",
|
||||
"value": "true"
|
||||
},
|
||||
{
|
||||
"type": "setValue",
|
||||
"name": "item:book",
|
||||
"value": "1"
|
||||
},
|
||||
{
|
||||
"type": "setValue",
|
||||
"name": "item:wand",
|
||||
"value": "1"
|
||||
},
|
||||
{
|
||||
"type": "setValue",
|
||||
"name": "item:I330",
|
||||
"value": "1"
|
||||
},
|
||||
{
|
||||
"type": "hideStatusBar"
|
||||
},
|
||||
@ -504,37 +474,62 @@ var data_a1e2fb4a_e986_4524_b0da_9b7ba7c0874d =
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"这是人类史上的一大进展",
|
||||
"在万物的发展中,任何物体都有它自己的发光点。",
|
||||
{
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"人类开始使用工具",
|
||||
"人类,这个起初完全不起眼的种族,",
|
||||
{
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"人类开始使用武器",
|
||||
"却在那一天发生了惊天的变动。",
|
||||
{
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"人类开始狩猎",
|
||||
"那曾是一个不起眼的日子。",
|
||||
{
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"人类终于摆脱了四肢行走",
|
||||
"直到一记闪电劈在了山上。",
|
||||
{
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"它让人类创造无限可能",
|
||||
"山火蔓延,霎时间,茂密的树林已然变为了焦炭。",
|
||||
{
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"这是人类史上最辉煌的时刻",
|
||||
"山火的发生让野兽饥不择食,",
|
||||
{
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"无数的人类被野兽硬生生拖走。",
|
||||
{
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"那又是一个不起眼的日子,",
|
||||
{
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"却让人类又一次发生了翻天地覆的变化。",
|
||||
{
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"一位野蛮人,也是我们的主角,",
|
||||
{
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"踏上了属于他的旅途。",
|
||||
{
|
||||
"type": "sleep",
|
||||
"time": 1000
|
||||
|
@ -21,20 +21,18 @@ main.floors.MT0=
|
||||
[141,141,141,141, 0, 0, 0,141, 0, 0, 0,141, 33, 33,20040],
|
||||
[141, 34, 34,141, 0,141, 0, 0, 0,141, 0,494,482,482,20040],
|
||||
[141, 33, 33,492, 0,141, 0, 0, 0,141, 0,141, 33, 33,20040],
|
||||
[141, 34, 34,141, 0,141, 0,559, 0,141, 0,141,141,141,20040],
|
||||
[141,141,141,141, 0, 0,558, 46,560, 0, 0,141, 33, 33,20040],
|
||||
[141, 34, 34,141, 0,141, 45,559, 46,141, 0,141,141,141,20040],
|
||||
[141,141,141,141, 0, 0,558, 0,560, 0, 0,141, 33, 33,20040],
|
||||
[141, 33, 33,141, 0,141,367, 0,129,141, 0,494,482,482,20040],
|
||||
[141, 33, 33,492, 0,141,129, 0,129,141, 0,141, 33, 33,20040],
|
||||
[141,141,141,141,141,141,141,141,141,141,141,141,141,141,20040]
|
||||
],
|
||||
"firstArrive": [
|
||||
"\t[原始人]\b[up,hero]家里柴火不够了,今天又要去砍柴了啊",
|
||||
"\t[原始人]\b[up,hero]最好还能带点食物回来",
|
||||
"\t[原始人]\b[up,hero]希望不要遇到什么凶猛的动物吧",
|
||||
"\t[原始人]\b[up,hero]......",
|
||||
"\t[原始人]\b[up,hero]家里面那些奇怪的石头还是没办法移走",
|
||||
"\t[原始人]\b[up,hero]之后再想办法吧",
|
||||
"请耐心等待字体加载完成,否则很多地方显示会很奇怪,大概需要十秒,过一段时间打开任意界面再关闭即可",
|
||||
"\t[原始人]\b[up,hero]家里有没有柴火了,看来需要上山砍柴了啊。",
|
||||
"\t[原始人]\b[up,hero]刚刚经历过山火,山上的柴火也不多了。",
|
||||
"\t[原始人]\b[up,hero]为什么这么倒霉的事会摊在我头上。",
|
||||
"\t[原始人]\b[up,hero]哎,不管了,先出去看看再说。",
|
||||
"\r[red]注意!!!\r[]该塔新增了很多新的功能,同时对样板的ui进行了大幅度的改动,操作也有改变,由于内容过多,这里不再一一描述,具体请在道具栏查看百科全书!!百科全书是在你面前的几个道具中的其中一个",
|
||||
{
|
||||
"type": "function",
|
||||
"function": "function(){\ncore.showChapter('序章 起源');\n}"
|
||||
@ -46,7 +44,9 @@ main.floors.MT0=
|
||||
"\t[原始人]\b[up,hero]出去找些柴火"
|
||||
],
|
||||
"8,13": [
|
||||
"本塔有很多新的功能,所有的说明都详细地写在了前方的百科全书里面,里面包含所有的功能说明,不阅读可能会影响正常的游戏体验,请仔细阅读。"
|
||||
"本塔有很多新的功能,所有的说明都详细地写在了前方的百科全书里面,里面包含所有的功能说明,不阅读可能会影响正常的游戏体验,请仔细阅读。",
|
||||
"例如你现在首先感受到的应该是状态栏的变动,你可以打开百科全书阅读状态栏相关内容。里面包含状态栏的功能说明与布局说明等。",
|
||||
"注意百科全书中的内容非常基础详细,如果对魔塔有一定的了解,可以选择性地阅读。"
|
||||
],
|
||||
"8,12": [
|
||||
"该塔计分方式:生命+5000*黄钥匙+15000*蓝钥匙"
|
||||
|
@ -14,9 +14,10 @@ main.floors.MT1=
|
||||
"defaultGround": "T331",
|
||||
"bgm": "cave.mp3",
|
||||
"firstArrive": [
|
||||
"\t[原始人]\b[up,hero]今天还是有这些黏糊糊的东西吗",
|
||||
"\t[原始人]\b[up,hero]打过去就好了",
|
||||
"\t[原始人]\b[up,hero]他们的反抗能力很弱的",
|
||||
"\t[原始人]\b[up,hero]呼,今天也有这些黏糊糊的东西啊。",
|
||||
"\t[原始人]\b[up,hero]真是奇怪,自从那次山火之后这里就出现了这些东西。",
|
||||
"\t[原始人]\b[up,hero]真是搞不清他们的来历。",
|
||||
"\t[原始人]\b[up,hero]不过好在他们反抗能力很弱,随便打打就能打过去了。",
|
||||
{
|
||||
"type": "if",
|
||||
"condition": "(flag:hard===1)",
|
||||
@ -25,7 +26,7 @@ main.floors.MT1=
|
||||
"type": "confirm",
|
||||
"text": "是否阅读魔塔基本游戏规则(教程)",
|
||||
"yes": [
|
||||
"魔塔遵循你打我一下,我打你一下的原则,每次造成的伤害时己方攻击减去对方防御\n红宝石可以增加攻击,蓝宝石可以增加防御,血瓶增加血量\n打怪物可以获得经验和金币,经验可用于升级,金币可用于购物\n以上就是基本规则,祝您游戏愉快!"
|
||||
"魔塔遵循你打我一下,我打你一下的原则,每次造成的伤害为己方攻击减去对方防御\n红宝石可以增加攻击,蓝宝石可以增加防御,血瓶增加血量\n打怪物可以获得经验和金币,经验可用于升级,金币可用于购物\n以上就是基本规则,祝您游戏愉快!"
|
||||
],
|
||||
"no": [
|
||||
"祝您游戏愉快"
|
||||
|
@ -66,61 +66,27 @@ main.floors.MT5=
|
||||
"textfont": 20,
|
||||
"time": 25
|
||||
},
|
||||
"他们走出了洞穴!!!!!",
|
||||
"人类简史——起源篇",
|
||||
{
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"他们终于摆脱了那种远古的生活方式!",
|
||||
"走出山洞,看似一个不起眼的举动,却是一个让残酷的真相永远地消失在了历史中的举动。",
|
||||
{
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"此时此刻,他们站在了明亮的草地之上",
|
||||
"但是,这个举动,也是人类至今都能与自然和谐共处的根本。",
|
||||
{
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"身向高山,背临江水",
|
||||
{
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"此时此刻,他们站在了历史的转折处",
|
||||
{
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"前进之力,无法阻挡",
|
||||
{
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"此时此刻,星空闪耀着文明的曙光",
|
||||
{
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"普照世间,闪耀一世",
|
||||
{
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"点破苍穹,斩断寰宇",
|
||||
{
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"星星之火,可以燎原",
|
||||
{
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"文明之光,就在眼前!",
|
||||
"那些残酷的历史将无人知晓,那些人类的残忍杀戮将不会出现。",
|
||||
{
|
||||
"type": "playSound",
|
||||
"name": "paper.mp3"
|
||||
},
|
||||
"而这些源头便是这看似无足轻重的一个举动。",
|
||||
{
|
||||
"type": "setText",
|
||||
"text": [
|
||||
|
@ -18,27 +18,52 @@ main.floors.MT6=
|
||||
"type": "setCurtain",
|
||||
"time": 500
|
||||
},
|
||||
"\t[原始人]\b[down,hero]感觉今天和之前有些不大一样",
|
||||
"\t[原始人]\b[down,hero]......",
|
||||
"\t[原始人]\b[down,hero]等一下,草地上那是什么?",
|
||||
"\t[智慧结晶]\b[down,4,4]我是智慧的结晶,存储着大量的智慧",
|
||||
"\t[原始人]\b[down,hero]?还会说话?",
|
||||
"\t[智慧结晶]\b[down,4,4]不要大惊小怪,我只是后人的智慧凝结而成的结晶罢了",
|
||||
"\t[智慧结晶]\b[down,4,4]你可以吸收我的智慧,来让你更有智慧",
|
||||
"\t[智慧结晶]\b[down,4,4]这样,你便能做一些其他你现在做不到事情",
|
||||
"\t[原始人]\b[down,hero]所以,我只要把你拿在手上就行了?",
|
||||
"\t[智慧结晶]\b[down,4,4]不,你只需要捏碎我,便可吸收我的全部智慧",
|
||||
"\t[智慧结晶]\b[down,4,4]至于我会说话,只是后人给我的特有功能,让你知道我的能力而已",
|
||||
"\t[智慧结晶]\b[down,4,4]这个功能会在我完成任务后自动关闭",
|
||||
"\t[智慧结晶]\b[down,4,4]也就是说,马上我就不会说话了",
|
||||
"\t[智慧结晶]\b[down,4,4]现在,你懂我的能力了吗?",
|
||||
"\t[原始人]\b[down,hero]大概...懂了吧",
|
||||
"\t[智慧结晶]\b[down,4,4]嗯,那我就离开了,记得捏碎我哦!",
|
||||
"\t[原始人]\b[down,hero].......",
|
||||
"\t[原始人]\b[down,hero]试着去捏碎它吧",
|
||||
"\t[原始人]\b[down,hero]外面也有这些怪物吗。",
|
||||
"\t[原始人]\b[down,hero]看来上山会有很大的难度啊。",
|
||||
"\t[智慧结晶]\b[down,4,4]哦?看起来你需要一些帮助?",
|
||||
"\t[原始人]\b[down,hero]谁?谁在说话?",
|
||||
"\t[智慧结晶]\b[down,4,4]你往左边看看,那有一个绿色水晶,我就是那个绿色水晶。",
|
||||
{
|
||||
"type": "changePos",
|
||||
"direction": "right"
|
||||
},
|
||||
{
|
||||
"type": "sleep",
|
||||
"time": 300
|
||||
},
|
||||
{
|
||||
"type": "moveHero",
|
||||
"steps": [
|
||||
"right:1"
|
||||
]
|
||||
},
|
||||
"\t[原始人]\b[down,hero]这东西会说话?",
|
||||
"\t[智慧结晶]\b[down,4,4]对呀对呀。",
|
||||
"\t[智慧结晶]\b[down,4,4]我叫智慧结晶,是专门来帮助你的。",
|
||||
"\t[原始人]\b[down,hero]帮助我?你这样怎么帮助我?",
|
||||
"\t[智慧结晶]\b[down,4,4]别着急,我先给你说一下我的来历。",
|
||||
"\t[智慧结晶]\b[down,4,4]未来的人类想要拯救他们自己的世界,但是无能为力,只好向历史出手。",
|
||||
"\t[智慧结晶]\b[down,4,4]于是他们便通过一些方法将我们传送到了这里,让我们来帮助你们。",
|
||||
"\t[智慧结晶]\b[down,4,4]这样历史便会改写,他们才有可能成功。",
|
||||
"\t[原始人]\b[down,hero]那你怎么帮助我呢?",
|
||||
"\t[智慧结晶]\b[down,4,4]很简单,我有很多智慧,你只需要把我放到手里,我就会消失。",
|
||||
"\t[智慧结晶]\b[down,4,4]我的智慧也会传递给你,你也就能变强了。",
|
||||
"\t[原始人]\b[down,hero]智慧?智慧有什么用?",
|
||||
"\t[智慧结晶]\b[down,hero]之后你就会知道的。",
|
||||
{
|
||||
"type": "function",
|
||||
"function": "function(){\ncore.displayChapter(1);\n}"
|
||||
"function": "function(){\ncore.getNextItem();\n}"
|
||||
},
|
||||
{
|
||||
"type": "sleep",
|
||||
"time": 300
|
||||
},
|
||||
"智慧涌入了原始人的大脑",
|
||||
"\t[原始人]\b[down,hero]这种感觉...",
|
||||
"\t[原始人]\b[down,hero]感觉好像可以学习一些简单的东西了。",
|
||||
{
|
||||
"type": "function",
|
||||
"function": "function(){\ncore.showChapter('第一章 勇气');\n}"
|
||||
},
|
||||
{
|
||||
"type": "setValue",
|
||||
@ -54,11 +79,6 @@ main.floors.MT6=
|
||||
"type": "setValue",
|
||||
"name": "item:cross",
|
||||
"value": "1"
|
||||
},
|
||||
{
|
||||
"type": "sleep",
|
||||
"time": 3000,
|
||||
"noSkip": true
|
||||
}
|
||||
],
|
||||
"eachArrive": [],
|
||||
|
@ -343,7 +343,7 @@ var items_296f5d02_12fd_4166_a7c1_b5e830c9ee3a =
|
||||
"cross": {
|
||||
"cls": "constants",
|
||||
"name": "查看技能",
|
||||
"text": "技能查看器",
|
||||
"text": "查看勇士的技能",
|
||||
"canUseItemEffect": true,
|
||||
"useItemEffect": "core.openSkills();"
|
||||
},
|
||||
|
@ -5988,19 +5988,15 @@ var plugins_bb40132b_638b_4a9f_b028_d3fe47acc8d1 = {
|
||||
* @param {string} data
|
||||
*/
|
||||
function reloadCss(data) {
|
||||
const all = Array.from(document.getElementsByTagName('link'));
|
||||
all.forEach(v => {
|
||||
if (v.rel !== 'stylesheet') return;
|
||||
if (v.href === `http://127.0.0.1:3000/${data}`) {
|
||||
v.remove();
|
||||
const link = document.createElement('link');
|
||||
link.rel = 'stylesheet';
|
||||
link.type = 'text/css';
|
||||
link.href = data;
|
||||
document.head.appendChild(link);
|
||||
console.log(`css hot reload: ${data}`);
|
||||
}
|
||||
});
|
||||
const css = document.getElementById('mota-css');
|
||||
css.remove();
|
||||
const link = document.createElement('link');
|
||||
link.rel = 'stylesheet';
|
||||
link.type = 'text/css';
|
||||
link.href = data;
|
||||
link.id = 'mota-css';
|
||||
document.head.appendChild(link);
|
||||
console.log(`css hot reload: ${data}`);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -6262,6 +6258,7 @@ var plugins_bb40132b_638b_4a9f_b028_d3fe47acc8d1 = {
|
||||
};
|
||||
|
||||
this.showChapter = function (chapter) {
|
||||
if (main.replayChecking) return;
|
||||
core.plugin.chapterContent.value = chapter;
|
||||
core.plugin.chapterShowed.value = true;
|
||||
};
|
||||
@ -6319,14 +6316,32 @@ var plugins_bb40132b_638b_4a9f_b028_d3fe47acc8d1 = {
|
||||
for (const id in remain) {
|
||||
const name = core.material.enemys[id].name;
|
||||
now.push(`${title}(${floor}): ${name} * ${remain[id]}`);
|
||||
if (now.length === 20) {
|
||||
if (now.length === 10) {
|
||||
str.push(now.join('\n'));
|
||||
now = [];
|
||||
}
|
||||
}
|
||||
}
|
||||
if (now.length > 0) str.push(now.join('\n'));
|
||||
if (now.length > 0) {
|
||||
str.push(now.join('\n'));
|
||||
str[0] = `当前剩余怪物:\n${str[0]}`;
|
||||
}
|
||||
|
||||
return str;
|
||||
};
|
||||
},
|
||||
replay: function () {
|
||||
const replayableSettings = ['autoSkill'];
|
||||
|
||||
// 注册修改设置的录像操作
|
||||
core.registerReplayAction('settings', name => {
|
||||
if (!name.startsWith('set:')) return false;
|
||||
const [, setting, value] = name.split(':');
|
||||
const v = eval(value);
|
||||
if (typeof v !== 'boolean') return false;
|
||||
if (!replayableSettings.includes(setting)) return false;
|
||||
flags[setting] = v;
|
||||
return true;
|
||||
});
|
||||
}
|
||||
};
|
||||
|
@ -109,7 +109,6 @@ body {
|
||||
}
|
||||
|
||||
#startLogo {
|
||||
user-select: none;
|
||||
position: absolute;
|
||||
z-index: 290;
|
||||
left: 0;
|
||||
@ -118,21 +117,37 @@ body {
|
||||
margin-right: auto;
|
||||
margin-top: 8%;
|
||||
max-width: 100%;
|
||||
color: transparent;
|
||||
text-align: center;
|
||||
font: bold 4em STXingkai;
|
||||
font: 4em 'normal';
|
||||
font-weight: 200;
|
||||
background-image: linear-gradient(
|
||||
to right,
|
||||
rgb(0, 0, 0),
|
||||
rgb(44, 44, 44),
|
||||
rgb(136, 0, 214),
|
||||
rgb(0, 2, 97),
|
||||
rgb(0, 2, 97)
|
||||
);
|
||||
background-clip: text;
|
||||
-webkit-background-clip: text;
|
||||
text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.5),
|
||||
-1px -1px 3px rgba(255, 255, 255, 0.3), 5px 5px 5px rgba(0, 0, 0, 0.4);
|
||||
filter: brightness(1.8);
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
#startTitle {
|
||||
user-select: none;
|
||||
position: absolute;
|
||||
z-index: 280;
|
||||
}
|
||||
|
||||
#startButtonGroup {
|
||||
width: auto;
|
||||
width: 33%;
|
||||
position: absolute;
|
||||
text-align: center;
|
||||
font-size: 1.4em;
|
||||
font-family: 'normal';
|
||||
display: none;
|
||||
z-index: 310;
|
||||
bottom: 0;
|
||||
@ -140,14 +155,50 @@ body {
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
padding: 15px 25px;
|
||||
min-width: 20%;
|
||||
/* default value */
|
||||
background-color: #32369f;
|
||||
opacity: 0.85;
|
||||
color: #ffffff;
|
||||
border: #ffffff 2px solid;
|
||||
background-image: linear-gradient(
|
||||
to bottom,
|
||||
rgba(76, 73, 255, 0.7),
|
||||
rgba(106, 40, 145, 0.7)
|
||||
);
|
||||
border: #ffffff 1px solid;
|
||||
caret-color: #ffd700;
|
||||
border-radius: 10px;
|
||||
text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.4),
|
||||
0px 0px 1px rgba(255, 255, 255, 0.3);
|
||||
}
|
||||
|
||||
#playGame {
|
||||
color: transparent;
|
||||
background-image: linear-gradient(
|
||||
to bottom,
|
||||
rgb(255, 255, 255),
|
||||
rgb(0, 255, 255)
|
||||
);
|
||||
background-clip: text;
|
||||
-webkit-background-clip: text;
|
||||
}
|
||||
|
||||
#loadGame {
|
||||
color: transparent;
|
||||
background-image: linear-gradient(
|
||||
to bottom,
|
||||
rgb(255, 255, 255),
|
||||
rgb(0, 255, 55)
|
||||
);
|
||||
background-clip: text;
|
||||
-webkit-background-clip: text;
|
||||
}
|
||||
|
||||
#replayGame {
|
||||
color: transparent;
|
||||
background-image: linear-gradient(
|
||||
to bottom,
|
||||
rgb(255, 255, 255),
|
||||
rgb(255, 251, 0)
|
||||
);
|
||||
background-clip: text;
|
||||
-webkit-background-clip: text;
|
||||
}
|
||||
|
||||
#startButtons {
|
||||
@ -158,17 +209,45 @@ body {
|
||||
display: none;
|
||||
}
|
||||
|
||||
#easy {
|
||||
background-image: linear-gradient(
|
||||
to bottom,
|
||||
rgb(255, 255, 255),
|
||||
rgb(87, 255, 72)
|
||||
);
|
||||
}
|
||||
|
||||
span#hard {
|
||||
background-image: linear-gradient(
|
||||
to bottom,
|
||||
rgb(255, 255, 255),
|
||||
rgb(255, 0, 0)
|
||||
);
|
||||
}
|
||||
|
||||
#levelChooseButtons span {
|
||||
color: transparent;
|
||||
background-clip: text;
|
||||
-webkit-background-clip: text;
|
||||
}
|
||||
|
||||
.startButton {
|
||||
width: 100%;
|
||||
margin: 0;
|
||||
font-weight: bold;
|
||||
display: block;
|
||||
cursor: pointer;
|
||||
padding: 4px 0;
|
||||
border-color: transparent;
|
||||
border-width: 2px;
|
||||
border-style: solid;
|
||||
border-radius: 6px;
|
||||
transition: box-shadow 0.3s linear, transform 0.3s linear;
|
||||
box-shadow: 0px 0px 7px rgba(0, 0, 0, 0.4);
|
||||
transform: scale(1);
|
||||
}
|
||||
|
||||
.startButton:hover {
|
||||
transform: scale(1.2);
|
||||
}
|
||||
|
||||
.onChoiceAnimate {
|
||||
|
@ -133,14 +133,16 @@ function bottomDrag(x: number, y: number) {
|
||||
}
|
||||
|
||||
function resize() {
|
||||
move = document.getElementById(`box-move-${id}`) as HTMLDivElement;
|
||||
main = document.getElementById(`box-${id}`) as HTMLDivElement;
|
||||
move = document.getElementById(`box-move-${id}`) as HTMLDivElement;
|
||||
leftB = document.getElementById(`border-left-${id}`) as HTMLDivElement;
|
||||
topB = document.getElementById(`border-top-${id}`) as HTMLDivElement;
|
||||
rightB = document.getElementById(`border-right-${id}`) as HTMLDivElement;
|
||||
bottomB = document.getElementById(`border-bottom-${id}`) as HTMLDivElement;
|
||||
drag = document.getElementById(`box-drag-${id}`) as HTMLElement;
|
||||
|
||||
if (!main) return;
|
||||
|
||||
if (has(props.left)) left.value = props.left;
|
||||
if (has(props.top)) top.value = props.top;
|
||||
if (has(props.width)) width.value = props.width;
|
||||
@ -158,6 +160,8 @@ onMounted(async () => {
|
||||
await sleep(50);
|
||||
resize();
|
||||
|
||||
if (!main) return;
|
||||
|
||||
useDrag(
|
||||
drag,
|
||||
dragFn,
|
||||
|
@ -69,14 +69,13 @@
|
||||
>
|
||||
</div>
|
||||
<div class="detail-info">
|
||||
<span style="color: cyan"
|
||||
>{{
|
||||
core.formatBigNumber(core.status.thisMap.ratio)
|
||||
}}防 {{
|
||||
core.formatBigNumber(enemy.defDamage)
|
||||
<span :style="{color: enemy.damageColor! as string}"
|
||||
>伤害 {{
|
||||
core.formatBigNumber(enemy.damage!)
|
||||
}}</span
|
||||
>
|
||||
</div>
|
||||
|
||||
<div class="detail-info">
|
||||
<span style="color: lightsalmon"
|
||||
>临界 {{
|
||||
@ -107,9 +106,11 @@
|
||||
>
|
||||
</div>
|
||||
<div class="detail-info">
|
||||
<span :style="{color: enemy.damageColor! as string}"
|
||||
>伤害 {{
|
||||
core.formatBigNumber(enemy.damage!)
|
||||
<span style="color: cyan"
|
||||
>{{
|
||||
core.formatBigNumber(core.status.thisMap.ratio)
|
||||
}}防 {{
|
||||
core.formatBigNumber(enemy.defDamage)
|
||||
}}</span
|
||||
>
|
||||
</div>
|
||||
@ -211,7 +212,7 @@ function enter() {
|
||||
|
||||
.detail {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
flex-direction: row;
|
||||
flex-wrap: wrap;
|
||||
height: 100%;
|
||||
|
||||
|
@ -16,7 +16,37 @@
|
||||
"如果你觉得状态栏有些碍事,你完全可以将其缩小,或者把它放到不碍事的地方。",
|
||||
"<br>",
|
||||
"<br>",
|
||||
"状态栏上面可能会有按钮(在开启技能树后会出现),你可以直接点击。"
|
||||
"状态栏上面可能会有按钮(在开启技能树后会出现),你可以直接点击。",
|
||||
"<br>",
|
||||
"<br>",
|
||||
"对状态栏布局的说明。",
|
||||
"<br>",
|
||||
"本塔的状态栏的布局较为灵活。它是横向的布局,在状态栏较宽时可以看到,属性会横向依次显示。按照显示顺序,",
|
||||
"状态栏显示项依次为:",
|
||||
"<br>",
|
||||
"1. 楼层名",
|
||||
"<br>",
|
||||
"2. 勇士等级",
|
||||
"<br>",
|
||||
"3. 当前开启的技能",
|
||||
"<br>",
|
||||
"4. 当前勇士生命值,右方偏下为每回合回复的生命值,当点开治愈之泉技能时,右方偏上会显示距离增加生命回复剩余血瓶数",
|
||||
"<br>",
|
||||
"5. 当前勇士的攻击,右方偏下为勇士的额外攻击",
|
||||
"<br>",
|
||||
"6. 当前勇士的防御",
|
||||
"<br>",
|
||||
"7. 当前勇士的智慧,可以用于智慧加点等",
|
||||
"<br>",
|
||||
"8. 当前勇士的金币",
|
||||
"<br>",
|
||||
"9. 当前勇士距离升级剩余经验数",
|
||||
"<br>",
|
||||
"10. 三色钥匙",
|
||||
"<br>",
|
||||
"11. 打开技能树(进入第一章后开启)",
|
||||
"<br>",
|
||||
"12. 查看勇士的技能(进入第一章后开启)"
|
||||
]
|
||||
},
|
||||
"markEnemy": {
|
||||
@ -101,5 +131,28 @@
|
||||
"电脑端和手机端均会显示装备增加或减少的属性,注意有的装备可能不增加属性但是有特殊功能。对于电脑端,",
|
||||
"还会直接在勇士属性栏显示增加或减少的属性。"
|
||||
]
|
||||
},
|
||||
"extraAttr": {
|
||||
"text": "勇士属性",
|
||||
"desc": [
|
||||
"这里只对本塔中新增的勇士属性进行说明。",
|
||||
"<br>",
|
||||
"<br>",
|
||||
"<span style=\"color: lightblue\">1. 智慧</span>:",
|
||||
"智慧是该塔的核心属性之一。智慧可用于智慧加点,该功能会在进入第一章后开启。使用智慧可以点技能树。",
|
||||
"除此之外,智慧也有其它功能。例如点开无上之盾技能后智慧还可以充当护盾,第二章点开学习技能后可以使用智慧学习怪物技能等。",
|
||||
"<br>",
|
||||
"<br>",
|
||||
"<span style=\"color: lightgreen\">2. 生命回复</span>:",
|
||||
"生命回复指的是勇士每回合回复的生命值。当与怪物战斗时,勇士每回合都会回复对应量的生命值。因此,当吃攻击时,",
|
||||
"与怪物战斗的回合数可能会减少,导致生命回复的总回复量减少。不过大部分情况下不需要在意这一点,",
|
||||
"减少一回合并不会对吸的血造成很大的影响。该项会显示在状态栏的生命值右方偏下的位置",
|
||||
"<br>",
|
||||
"<br>",
|
||||
"<span style=\"color: lightcoral\">3. 额外攻击</span>:",
|
||||
"额外攻击指的是勇士每回合的额外造成的伤害。一般情况下,当勇士破了怪物的防御时,该项便会起作用。",
|
||||
"额外攻击相当于魔攻,无法通过一般方式减免。当勇士攻击怪物时,每回合都会附加对应量的伤害,对坚固怪同样有效。",
|
||||
"额外攻击会显示在状态栏的攻击右方偏下的位置"
|
||||
]
|
||||
}
|
||||
}
|
@ -1,6 +1,18 @@
|
||||
{
|
||||
"transition": {
|
||||
"text": "界面动画",
|
||||
"desc": "是否展示当一个ui界面,如怪物手册等的打开与关闭时的动画。当此项开启时,所有界面被打开或关闭时都会展示动画,否则会直接展示出来"
|
||||
"desc": [
|
||||
"是否展示当一个ui界面,如怪物手册等的打开与关闭时的动画。当此项开启时,所有界面被打开或关闭时都会展示动画,否则会直接展示出来"
|
||||
]
|
||||
},
|
||||
"itemDetail": {
|
||||
"text": "宝石血瓶显伤",
|
||||
"desc": ["是否在地图上显示宝石血瓶装备等增加的属性值"]
|
||||
},
|
||||
"autoSkill": {
|
||||
"text": "自动切换技能",
|
||||
"desc": [
|
||||
"开启后,打怪物的时候会自动选择伤害最低的技能。同时显伤也会显示此状态下的伤害。"
|
||||
]
|
||||
}
|
||||
}
|
||||
|
@ -5,11 +5,32 @@ import { ref, watch } from 'vue';
|
||||
*/
|
||||
export const transition = ref(true);
|
||||
|
||||
/**
|
||||
* 道具详细信息
|
||||
*/
|
||||
export const itemDetail = ref(true);
|
||||
|
||||
/**
|
||||
* 自动切换技能
|
||||
*/
|
||||
export const autoSkill = ref(true);
|
||||
|
||||
watch(transition, n => {
|
||||
core.plugin.transition.value = n;
|
||||
core.setLocalStorage('transition', n);
|
||||
});
|
||||
|
||||
watch(itemDetail, n => {
|
||||
flags.itemDetail = n;
|
||||
core.updateStatusBar();
|
||||
});
|
||||
|
||||
watch(autoSkill, n => {
|
||||
flags.autoSkill = n;
|
||||
core.updateStatusBar();
|
||||
core.status.route.push(`set:autoSkill:${n}`);
|
||||
});
|
||||
|
||||
/**
|
||||
* 重置设置信息,从localStorage读取即可
|
||||
*/
|
||||
@ -17,6 +38,11 @@ function reset() {
|
||||
transition.value = core.getLocalStorage('transition');
|
||||
}
|
||||
|
||||
export default function init() {
|
||||
return { resetSettings: reset };
|
||||
function resetFlag() {
|
||||
itemDetail.value = flags.itemDetail;
|
||||
autoSkill.value = flags.autoSkill;
|
||||
}
|
||||
|
||||
export default function init() {
|
||||
return { resetSettings: reset, resetFlagSettings: resetFlag };
|
||||
}
|
||||
|
@ -35,8 +35,8 @@ export function getDamageColor(damage: number): Color {
|
||||
if (damage < 0) return '#7f7';
|
||||
if (damage < core.status.hero.hp / 3) return '#fff';
|
||||
if (damage < (core.status.hero.hp * 2) / 3) return '#ff4';
|
||||
if (damage < core.status.hero.hp) return '#f22';
|
||||
return '#f00';
|
||||
if (damage < core.status.hero.hp) return '#f93';
|
||||
return '#f22';
|
||||
}
|
||||
|
||||
/**
|
||||
|
5
src/types/plugin.d.ts
vendored
5
src/types/plugin.d.ts
vendored
@ -69,6 +69,11 @@ interface PluginDeclaration extends PluginUtils, PluginUis, PluginUse {
|
||||
* 重置设置信息
|
||||
*/
|
||||
resetSettings(): void;
|
||||
|
||||
/**
|
||||
* 重置变量的设置信息
|
||||
*/
|
||||
resetFlagSettings(): void;
|
||||
}
|
||||
|
||||
interface PluginUtils {
|
||||
|
@ -15,13 +15,13 @@ const props = defineProps<{
|
||||
chapter: string;
|
||||
}>();
|
||||
|
||||
let canvas: HTMLCanvasElement;
|
||||
let can: HTMLCanvasElement;
|
||||
let ctx: CanvasRenderingContext2D;
|
||||
let text: HTMLSpanElement;
|
||||
|
||||
onMounted(async () => {
|
||||
canvas = document.getElementById('chapter-back') as HTMLCanvasElement;
|
||||
ctx = canvas.getContext('2d')!;
|
||||
can = document.getElementById('chapter-back') as HTMLCanvasElement;
|
||||
ctx = can.getContext('2d')!;
|
||||
text = document.getElementById('chapter-text') as HTMLSpanElement;
|
||||
|
||||
const ani = new Animation();
|
||||
@ -36,10 +36,10 @@ onMounted(async () => {
|
||||
ani.register('rect2', h / 2);
|
||||
ani.register('text', window.innerWidth + 10 + textWidth);
|
||||
|
||||
canvas.width = w;
|
||||
canvas.height = h;
|
||||
canvas.style.width = `${window.innerWidth}px`;
|
||||
canvas.style.height = `${window.innerHeight}px`;
|
||||
can.width = w;
|
||||
can.height = h;
|
||||
can.style.width = `${window.innerWidth}px`;
|
||||
can.style.height = `${window.innerHeight}px`;
|
||||
text.style.left = `${w + 10}px`;
|
||||
text.style.top = `${window.innerHeight / 2 - h * 0.025}px`;
|
||||
text.style.height = `${h * 0.05}px`;
|
||||
@ -55,7 +55,10 @@ onMounted(async () => {
|
||||
return;
|
||||
}
|
||||
|
||||
if (time >= 4000) chapterShowed.value = false;
|
||||
if (time >= 4000) {
|
||||
chapterShowed.value = false;
|
||||
ani.ticker.destroy();
|
||||
}
|
||||
|
||||
if (!soundPlayed && time >= 1500) {
|
||||
soundPlayed = true;
|
||||
@ -114,9 +117,6 @@ onMounted(async () => {
|
||||
ani.mode(hyper('sin', 'in')).time(1000).apply('rect2', 0);
|
||||
await sleep(1000);
|
||||
ani.mode(hyper('sin', 'out')).time(1000).apply('lineOpacity', 0);
|
||||
|
||||
await sleep(1000);
|
||||
ani.ticker.destroy();
|
||||
});
|
||||
</script>
|
||||
|
||||
|
@ -25,13 +25,13 @@
|
||||
>伤害:{{ getDamage(v) }}</span
|
||||
>
|
||||
<span class="marked-critical marked-item"
|
||||
>临界: {{ getCritical(v)[0] }}</span
|
||||
>临界:{{ getCritical(v)[0] }}</span
|
||||
>
|
||||
<span class="marked-critical-damage marked-item"
|
||||
>减伤: {{ getCritical(v)[1] }}</span
|
||||
>减伤:{{ getCritical(v)[1] }}</span
|
||||
>
|
||||
<span class="marked-def marked-item"
|
||||
>{{ ratio }}防: {{ getDefDamage(v) }}</span
|
||||
>{{ ratio }}防:{{ getDefDamage(v) }}</span
|
||||
>
|
||||
<div class="marked-button">
|
||||
<span
|
||||
|
@ -11,11 +11,27 @@
|
||||
<span
|
||||
class="selectable setting-item"
|
||||
:selected="selected === 'transition'"
|
||||
@click="transition = !transition"
|
||||
@click="click('transition')"
|
||||
>界面动画: {{
|
||||
transition ? 'ON' : 'OFF'
|
||||
}}</span
|
||||
>
|
||||
<span
|
||||
class="selectable setting-item"
|
||||
:selected="selected === 'itemDetail'"
|
||||
@click="click('itemDetail')"
|
||||
>宝石血瓶显伤: {{
|
||||
itemDetail ? 'ON' : 'OFF'
|
||||
}}</span
|
||||
>
|
||||
<span
|
||||
class="selectable setting-item"
|
||||
:selected="selected === 'autoSkill'"
|
||||
@click="click('autoSkill')"
|
||||
>自动切换技能: {{
|
||||
autoSkill ? 'ON' : 'OFF'
|
||||
}}</span
|
||||
>
|
||||
</div>
|
||||
</Scroll>
|
||||
<a-divider
|
||||
@ -24,11 +40,7 @@
|
||||
></a-divider>
|
||||
<div id="setting-right">
|
||||
<Scroll style="height: 100%">
|
||||
<span
|
||||
v-if="descText.value.startsWith('!!html')"
|
||||
v-html="descText.value"
|
||||
></span>
|
||||
<span v-else>{{ descText.value }}</span>
|
||||
<span v-html="descText"></span>
|
||||
</Scroll>
|
||||
</div>
|
||||
</div>
|
||||
@ -36,10 +48,10 @@
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { computed, ref, watch } from 'vue';
|
||||
import { transition } from '../plugin/settings';
|
||||
import { computed, ref } from 'vue';
|
||||
import { transition, itemDetail, autoSkill } from '../plugin/settings';
|
||||
import settingInfo from '../data/settings.json';
|
||||
import { type } from '../plugin/utils';
|
||||
import { has } from '../plugin/utils';
|
||||
import Scroll from '../components/scroll.vue';
|
||||
import { LeftOutlined } from '@ant-design/icons-vue';
|
||||
import { isMobile } from '../plugin/use';
|
||||
@ -49,12 +61,36 @@ type Settings = typeof settingInfo;
|
||||
const selected = ref<keyof Settings>('transition');
|
||||
|
||||
const descText = computed(() => {
|
||||
return type(settingInfo[selected.value].desc);
|
||||
return settingInfo[selected.value].desc
|
||||
.map((v, i, a) => {
|
||||
if (/^\d+\./.test(v)) return `${' '.repeat(12)}${v}`;
|
||||
else if (
|
||||
(has(a[i - 1]) && v !== '<br>' && a[i - 1] === '<br>') ||
|
||||
i === 0
|
||||
) {
|
||||
return `${' '.repeat(8)}${v}`;
|
||||
} else return v;
|
||||
})
|
||||
.join('');
|
||||
});
|
||||
|
||||
function exit() {
|
||||
core.plugin.settingsOpened.value = false;
|
||||
}
|
||||
|
||||
function click(id: keyof Settings) {
|
||||
if (selected.value !== id) {
|
||||
selected.value = id;
|
||||
return;
|
||||
}
|
||||
if (id === 'transition') {
|
||||
transition.value = !transition.value;
|
||||
} else if (id === 'itemDetail') {
|
||||
itemDetail.value = !itemDetail.value;
|
||||
} else if (id === 'autoSkill') {
|
||||
autoSkill.value = !autoSkill.value;
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
|
@ -84,10 +84,18 @@
|
||||
}}</span>
|
||||
</div>
|
||||
<div v-if="skillOpened" class="status-item">
|
||||
<span id="skill-tree" class="button-text">技能树</span>
|
||||
<span
|
||||
id="skill-tree"
|
||||
class="button-text"
|
||||
@click="openSkillTree"
|
||||
>技能树</span
|
||||
>
|
||||
</div>
|
||||
<div v-if="skillOpened" class="status-item">
|
||||
<span id="status-skill" class="button-text"
|
||||
<span
|
||||
id="status-skill"
|
||||
class="button-text"
|
||||
@click="openSkill"
|
||||
>查看技能</span
|
||||
>
|
||||
</div>
|
||||
@ -161,6 +169,16 @@ function update() {
|
||||
}
|
||||
skillOpened.value = core.getFlag('chapter', 0) > 0;
|
||||
}
|
||||
|
||||
function openSkillTree(e: MouseEvent) {
|
||||
e.stopPropagation();
|
||||
core.useItem('skill1');
|
||||
}
|
||||
|
||||
function openSkill(e: MouseEvent) {
|
||||
e.stopPropagation();
|
||||
core.useItem('cross');
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
@ -213,6 +231,7 @@ function update() {
|
||||
font-size: 1.9vw;
|
||||
width: 100%;
|
||||
text-align: center;
|
||||
text-shadow: 3px 2px 3px #000, 0px 0px 3px #111;
|
||||
}
|
||||
|
||||
#status-lv {
|
||||
@ -220,6 +239,7 @@ function update() {
|
||||
font-size: 1.9vw;
|
||||
width: 100%;
|
||||
text-align: center;
|
||||
text-shadow: 3px 2px 3px #000, 0px 0px 3px #111;
|
||||
}
|
||||
|
||||
.status-extra {
|
||||
|
Loading…
Reference in New Issue
Block a user