Compare commits

..

2 Commits

Author SHA1 Message Date
9e4d6262c7 Merge branch 'noAnimate' into hasAnimate 2022-12-30 18:38:58 +08:00
7add89690c 新增一个插件用于仿RM的跳过剧情
修改了0-10层(不含隐藏)跳过剧情的表现
2022-12-30 18:36:34 +08:00
10 changed files with 2431 additions and 1919 deletions

View File

@ -367,6 +367,7 @@ var data_a1e2fb4a_e986_4524_b0da_9b7ba7c0874d =
"tawaijiuren.png",
"terrains.png",
"tiantawai.png",
"tiaojuqing.png",
"tr003.jpg",
"wangyangdan.png",
"wangyangqianxiao.png",

View File

@ -522,23 +522,29 @@ main.floors.MT0=
],
"8,8": [
{
"type": "choices",
"text": "是否跳过剧情",
"choices": [
"type": "if",
"condition": "(core.isReplaying()||flag:SkipThePlot)",
"true": [
{
"text": "是",
"action": [
"type": "setValue",
"name": "flag:SkipThePlot",
"value": "false"
},
{
"type": "hide",
"remove": true,
"time": 500
},
{
"type": "if",
"condition": "(core.getBlock(8,6)===null)",
"true": [
{
"type": "setBlock",
"number": "fairy",
"loc": [
[
9,
8,
6
]
],
@ -547,8 +553,51 @@ main.floors.MT0=
]
},
{
"text": "否",
"action": [
"type": "move",
"loc": [
8,
6
],
"time": 100,
"keep": true,
"steps": [
"right:1"
]
}
],
"false": [
{
"type": "showImage2",
"code": 10,
"image": "tiaojuqing.png",
"sloc": [
0,
0,
null
],
"loc": [
700,
0,
243,
"71.25"
],
"opacity": 1,
"time": 0
},
{
"type": "moveImage",
"code": 10,
"to": [
400,
0
],
"time": 500
},
{
"type": "setValue",
"name": "flag:useS_PASS",
"value": "true"
},
{
"type": "sleep",
"time": 1000
@ -730,6 +779,25 @@ main.floors.MT0=
"\t[???]你......你好.........",
"\t[邵虎]........你是谁........",
"\t[???]我是这座塔的守塔仙子........",
{
"type": "setValue",
"name": "flag:useS_PASS",
"value": "false"
},
{
"type": "moveImage",
"code": 10,
"to": [
700,
0
],
"time": 500
},
{
"type": "hideImage",
"code": 10,
"time": 0
},
"\t[守塔仙子]邵....啊不.....这位勇士,请你回去吧。塔里过于凶险..........",
"\t[邵虎]谢谢你的好意....不过我还是要进去的。",
"\t[守塔仙子]为什么......这座塔并没有什么宝藏,也不值得你来探索......",
@ -851,8 +919,6 @@ main.floors.MT0=
]
}
]
}
]
},
{
"type": "setValue",

View File

@ -60,16 +60,48 @@ main.floors.MT1=
],
"false": [
{
"type": "choices",
"text": "是否跳过剧情",
"choices": [
"type": "if",
"condition": "(core.isReplaying()||flag:SkipThePlot)",
"true": [
{
"text": "是",
"action": []
"type": "setValue",
"name": "flag:SkipThePlot",
"value": "false"
}
],
"false": [
{
"type": "showImage2",
"code": 10,
"image": "tiaojuqing.png",
"sloc": [
0,
0,
null
],
"loc": [
700,
0,
243,
"71.25"
],
"opacity": 1,
"time": 0
},
{
"text": "否",
"action": [
"type": "moveImage",
"code": 10,
"to": [
400,
0
],
"time": 500
},
{
"type": "setValue",
"name": "flag:useS_PASS",
"value": "true"
},
{
"type": "showImage2",
"code": 1,
@ -254,8 +286,25 @@ main.floors.MT1=
"type": "hideImage",
"code": 2,
"time": 0
}
]
},
{
"type": "setValue",
"name": "flag:useS_PASS",
"value": "false"
},
{
"type": "moveImage",
"code": 10,
"to": [
700,
0
],
"time": 500
},
{
"type": "hideImage",
"code": 10,
"time": 0
}
]
},

View File

@ -16,12 +16,14 @@ main.floors.MT10=
"name": "misjiqing.mp3"
},
{
"type": "choices",
"text": "是否跳过剧情",
"choices": [
"type": "if",
"condition": "(core.isReplaying()||flag:SkipThePlot)",
"true": [
{
"text": "是",
"action": [
"type": "setValue",
"name": "flag:SkipThePlot",
"value": "false"
},
{
"type": "setValue",
"name": "flag:skip10FStory",
@ -38,11 +40,40 @@ main.floors.MT10=
0
]
}
]
],
"false": [
{
"type": "showImage2",
"code": 10,
"image": "tiaojuqing.png",
"sloc": [
0,
0,
null
],
"loc": [
700,
0,
243,
"71.25"
],
"opacity": 1,
"time": 0
},
{
"text": "否",
"action": [
"type": "moveImage",
"code": 10,
"to": [
400,
0
],
"time": 500
},
{
"type": "setValue",
"name": "flag:useS_PASS",
"value": "true"
},
{
"type": "sleep",
"time": 1000
@ -171,6 +202,25 @@ main.floors.MT10=
"time": 500
},
"\t[嗜骨]..........其实.......",
{
"type": "setValue",
"name": "flag:useS_PASS",
"value": "false"
},
{
"type": "moveImage",
"code": 10,
"to": [
700,
0
],
"time": 500
},
{
"type": "hideImage",
"code": 10,
"time": 0
},
{
"type": "sleep",
"time": 2000
@ -225,8 +275,6 @@ main.floors.MT10=
}
]
}
]
}
],
"1,0": [
{

View File

@ -21,12 +21,14 @@ main.floors.MT5=
"6,5": null,
"1,0": [
{
"type": "choices",
"text": "是否跳过剧情",
"choices": [
"type": "if",
"condition": "(core.isReplaying()||flag:SkipThePlot)",
"true": [
{
"text": "是",
"action": [
"type": "setValue",
"name": "flag:SkipThePlot",
"value": "false"
},
{
"type": "setBlock",
"number": "354",
@ -66,12 +68,81 @@ main.floors.MT5=
]
],
"time": 0
}
]
},
{
"text": "否",
"action": [
"type": "hide",
"loc": [
[
6,
5
]
],
"time": 0
},
{
"type": "hide",
"loc": [
[
6,
3
]
],
"time": 0
},
{
"type": "hide",
"loc": [
[
5,
3
]
],
"time": 0
},
{
"type": "hide",
"loc": [
[
4,
3
]
],
"time": 0
}
],
"false": [
{
"type": "showImage2",
"code": 10,
"image": "tiaojuqing.png",
"sloc": [
0,
0,
null
],
"loc": [
700,
0,
243,
"71.25"
],
"opacity": 1,
"time": 0
},
{
"type": "moveImage",
"code": 10,
"to": [
400,
0
],
"time": 500
},
{
"type": "setValue",
"name": "flag:useS_PASS",
"value": "true"
},
{
"type": "playBgm",
"name": "linghaihuanxin.mp3"
@ -348,6 +419,25 @@ main.floors.MT5=
"code": 1,
"time": 0
},
{
"type": "setValue",
"name": "flag:useS_PASS",
"value": "false"
},
{
"type": "moveImage",
"code": 10,
"to": [
700,
0
],
"time": 500
},
{
"type": "hideImage",
"code": 10,
"time": 0
},
{
"type": "setVolume",
"value": 0,
@ -842,8 +932,6 @@ main.floors.MT5=
"time": 500
}
]
}
]
},
{
"type": "setValue",

View File

@ -46,16 +46,48 @@ main.floors.MT6=
],
"false": [
{
"type": "choices",
"text": "是否跳过剧情",
"choices": [
"type": "if",
"condition": "(core.isReplaying()||flag:SkipThePlot)",
"true": [
{
"text": "是",
"action": []
"type": "setValue",
"name": "flag:SkipThePlot",
"value": "false"
}
],
"false": [
{
"type": "showImage2",
"code": 10,
"image": "tiaojuqing.png",
"sloc": [
0,
0,
null
],
"loc": [
700,
0,
243,
"71.25"
],
"opacity": 1,
"time": 0
},
{
"text": "否",
"action": [
"type": "moveImage",
"code": 10,
"to": [
400,
0
],
"time": 500
},
{
"type": "setValue",
"name": "flag:useS_PASS",
"value": "true"
},
{
"type": "showImage2",
"code": 1,
@ -110,8 +142,25 @@ main.floors.MT6=
"type": "hideImage",
"code": 2,
"time": 0
}
]
},
{
"type": "setValue",
"name": "flag:useS_PASS",
"value": "false"
},
{
"type": "moveImage",
"code": 10,
"to": [
700,
0
],
"time": 500
},
{
"type": "hideImage",
"code": 10,
"time": 0
}
]
},

View File

@ -22,16 +22,48 @@ main.floors.MT7=
"value": "1"
},
{
"type": "choices",
"text": "是否跳过剧情",
"choices": [
"type": "if",
"condition": "(core.isReplaying()||flag:SkipThePlot)",
"true": [
{
"text": "是",
"action": []
"type": "setValue",
"name": "flag:SkipThePlot",
"value": "false"
}
],
"false": [
{
"type": "showImage2",
"code": 10,
"image": "tiaojuqing.png",
"sloc": [
0,
0,
null
],
"loc": [
700,
0,
243,
"71.25"
],
"opacity": 1,
"time": 0
},
{
"text": "否",
"action": [
"type": "moveImage",
"code": 10,
"to": [
400,
0
],
"time": 500
},
{
"type": "setValue",
"name": "flag:useS_PASS",
"value": "true"
},
{
"type": "showImage2",
"code": 1,
@ -188,6 +220,25 @@ main.floors.MT7=
"type": "hideImage",
"code": 2,
"time": 0
},
{
"type": "setValue",
"name": "flag:useS_PASS",
"value": "false"
},
{
"type": "moveImage",
"code": 10,
"to": [
700,
0
],
"time": 500
},
{
"type": "hideImage",
"code": 10,
"time": 0
}
],
"false": [
@ -218,8 +269,6 @@ main.floors.MT7=
]
}
]
}
]
},
{
"type": "setValue",

View File

@ -20,12 +20,14 @@ main.floors.MT9=
"events": {
"1,0": [
{
"type": "choices",
"text": "是否跳过剧情",
"choices": [
"type": "if",
"condition": "(core.isReplaying()||flag:SkipThePlot)",
"true": [
{
"text": "是",
"action": [
"type": "setValue",
"name": "flag:SkipThePlot",
"value": "false"
},
{
"type": "hide",
"loc": [
@ -46,11 +48,40 @@ main.floors.MT9=
],
"time": 0
}
]
],
"false": [
{
"type": "showImage2",
"code": 10,
"image": "tiaojuqing.png",
"sloc": [
0,
0,
null
],
"loc": [
700,
0,
243,
"71.25"
],
"opacity": 1,
"time": 0
},
{
"text": "否",
"action": [
"type": "moveImage",
"code": 10,
"to": [
400,
0
],
"time": 500
},
{
"type": "setValue",
"name": "flag:useS_PASS",
"value": "true"
},
{
"type": "move",
"loc": [
@ -191,8 +222,25 @@ main.floors.MT9=
"steps": [
"right:4"
]
}
]
},
{
"type": "setValue",
"name": "flag:useS_PASS",
"value": "false"
},
{
"type": "moveImage",
"code": 10,
"to": [
700,
0
],
"time": 500
},
{
"type": "hideImage",
"code": 10,
"time": 0
}
]
},

View File

Before

Width:  |  Height:  |  Size: 41 KiB

After

Width:  |  Height:  |  Size: 41 KiB

View File

@ -3625,5 +3625,119 @@ var plugins_bb40132b_638b_4a9f_b028_d3fe47acc8d1 =
return;
}
}
},
"按S跳过剧情": function () {
// 在此增加新插件
core.registerAction('keyDown', "useS_PASS", function (keycode) { /////按下某个键
if (!core.status.hero.flags.useS_PASS) return false;
}, 100);
var _my_useS_PASS = function (keycode) { ////放开某个键
if (!core.status.hero.flags.useS_PASS) return false;
if (keycode == 83) { ////按下S时
core.Confirmskip();
}
};
core.registerAction('keyUp', 'useS_PASS', _my_useS_PASS, 100);
core.registerAction('ondown', 'useS_PASS', function (x, y, px, py) {
if (!core.status.hero.flags.useS_PASS) return false;
if (x >= 7 && y <= 2) {
core.Confirmskip();
}
}, 100);
core.Confirmskip = function () { ////跳过剧情确认框
core.status.hero.flags.useS_PASS = false; ////禁用按S跳过
core.status.hero.flags.Confirmskip = true;
core.status.hero.flags.ConfirmskipChoose = 0;
core.createCanvas('Confirmskip', 0, 0, 480, 480, 200);
core.createCanvas('Confirmskip_text', 0, 0, 480, 480, 202);
core.drawWindowSkin('winskin.png', 'Confirmskip', 48, 182, 176, 96);
core.fillText('Confirmskip_text', '不跳过剧情', 70, 222, "#ffffff", ui.prototype._buildFont(22, false))
core.fillText('Confirmskip_text', '跳过剧情', 70, 248, "#ffffff", ui.prototype._buildFont(22, false))
core.drawUIEventSelector(1, 'winskin.png', 70, 202, 120, 24, 201); ////绘制光标
}
core.registerAction('keyDown', "Confirmskip", function (keycode) { /////按下某个键
if (!core.status.hero.flags.Confirmskip) return false;
return true; ///全部拦截
}, 100);
var _my_Confirmskip = function (keycode) { ////放开某个键
if (!core.status.hero.flags.Confirmskip) return false;
if ((keycode == 13 || keycode == 32 || keycode == 67)) { ////按下空格\回车\C时
if (core.status.hero.flags.ConfirmskipChoose === 1) { ///选择为跳过剧情
core.ConfirmskipOK();
} else { ///选择为不跳过剧情
core.status.hero.flags.useS_PASS = true; ////允许按S的开关
core.status.hero.flags.Confirmskip = false;
core.clearMap('Confirmskip') /////清除画布
core.clearMap('Confirmskip_text')
core.clearUIEventSelector(1); ////清除光标
}
} else if (keycode == 38 || keycode == 40) ///上下切换
{
core.setFlag('ConfirmskipChoose', 1 ^ (core.getFlag('ConfirmskipChoose') || 0));
if (core.status.hero.flags.ConfirmskipChoose === 0)
core.drawUIEventSelector(1, 'winskin.png', 70, 202, 120, 24, 201); ////绘制光标
else
core.drawUIEventSelector(1, 'winskin.png', 70, 229, 120, 24, 201); ////绘制光标
}
return true; ///全部拦截
};
core.registerAction('keyUp', 'Confirmskip', _my_Confirmskip, 100);
core.registerAction('ondown', 'Confirmskip', function (x, y, px, py) {
if (!core.status.hero.flags.Confirmskip) return false;
if (x >= 3 && x <= 6 && y === 6) {
if (core.status.hero.flags.ConfirmskipChoose === 0) {
///选择为不跳过剧情
core.status.hero.flags.useS_PASS = true; ////允许按S的开关
core.status.hero.flags.Confirmskip = false;
core.clearMap('Confirmskip') /////清除画布
core.clearMap('Confirmskip_text')
core.clearUIEventSelector(1); ////清除光标
} else
{
core.status.hero.flags.ConfirmskipChoose = 0;
core.drawUIEventSelector(1, 'winskin.png', 70, 202, 120, 24, 201); ////绘制光标
}
} else if (x >= 3 && x <= 6 && y === 7) {
if (core.status.hero.flags.ConfirmskipChoose === 1) {
core.ConfirmskipOK();
} else {
core.status.hero.flags.ConfirmskipChoose = 1;
core.drawUIEventSelector(1, 'winskin.png', 70, 229, 120, 24, 201); ////绘制光标
}
}
return true; ///全部拦截
}, 100);
core.ConfirmskipOK = function () { ////决定跳过剧情
core.status.hero.flags.Confirmskip = false;
core.clearMap('Confirmskip') /////清除画布
core.clearMap('Confirmskip_text')
core.clearUIEventSelector(1); ////清除光标
core.deleteAllCanvas(); ///清空画布
core.status.hero.flags.SkipThePlot = true; ////跳过事件开关
core.insertAction({ "type": "exit" });
core.insertAction({ "type": "insert" }); ///重新触发当前事件
core.doAction(); ///执行下一个事件
}
}
}