From 2592d293d34c7e43d30ab46af3a32903b2e2baf5 Mon Sep 17 00:00:00 2001 From: ckcz123 Date: Fri, 20 Aug 2021 13:37:26 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=B0=E5=BB=BA=E6=A5=BC=E5=B1=82=E4=BF=9D?= =?UTF-8?q?=E7=95=99=E5=88=9B=E5=BB=BA=E7=9A=84=E5=B1=9E=E6=80=A7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- _server/MotaActionParser.js | 2 +- _server/editor_file.js | 10 +++++++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/_server/MotaActionParser.js b/_server/MotaActionParser.js index 7f642a9f..b9ec1c6f 100644 --- a/_server/MotaActionParser.js +++ b/_server/MotaActionParser.js @@ -322,7 +322,7 @@ ActionParser.prototype.parseAction = function() { data.time, data.lineHeight||1.4, data.async||false, this.EvalString_Multi(data.text), this.next]); break; case "comment": // 注释 - this.next = MotaActionBlocks['comment_s'].xmlText([this.EvalString_Multi(data.text),this.next],null,data.text); + this.next = MotaActionBlocks['comment_s'].xmlText([this.EvalString_Multi(data.text),this.next]); break; case "setText": // 设置剧情文本的属性 data.title=this.Colour(data.title); diff --git a/_server/editor_file.js b/_server/editor_file.js index 14cee7db..519e1a2e 100644 --- a/_server/editor_file.js +++ b/_server/editor_file.js @@ -219,7 +219,15 @@ editor_file = function (editor, callback) { color: currData.color, weather: currData.weather, }:{}); - + // 继承配置表格新增的基本楼层属性 + if (saveStatus) { + for (var x in currData) { + if (editor.currentFloorData[x] == null && (typeof currData[x] == 'number' || typeof currData[x] == 'string')) { + editor.currentFloorData[x] = currData[x]; + } + } + } + Object.keys(editor.currentFloorData).forEach(function (t) { if (editor.currentFloorData[t] == null) delete editor.currentFloorData[t];