From f86591413984c3bf6e6d1e2decdc943a3dccd4fb Mon Sep 17 00:00:00 2001 From: ckcz123 Date: Thu, 4 Jun 2020 12:05:49 +0800 Subject: [PATCH] =?UTF-8?q?=E4=B8=80=E4=BA=9B=E7=BB=86=E8=8A=82=E7=9A=84?= =?UTF-8?q?=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- _server/MotaAction.g4 | 8 +++----- _server/MotaActionParser.js | 2 ++ _server/table/comment.js | 2 +- editor-mobile.html | 1 + editor.html | 1 + libs/events.js | 29 ++++++++++++++++++++--------- 6 files changed, 28 insertions(+), 15 deletions(-) diff --git a/_server/MotaAction.g4 b/_server/MotaAction.g4 index 5cd8fe43..77ecf791 100644 --- a/_server/MotaAction.g4 +++ b/_server/MotaAction.g4 @@ -1258,7 +1258,6 @@ tooltip : showFloorImg: 显示一个贴图,xy为左上角坐标,可用逗号 helpUrl : https://h5mota.com/games/template/_docs/#/event?id=showFloorImg%ef%bc%9a%e6%98%be%e7%a4%ba%e8%b4%b4%e5%9b%be default : ["","",""] allFloorIds : ['IdString_0'] -selectPoint : ["EvalString_0", "EvalString_1", "IdString_0"] colour : this.mapColor var floorstr = ''; if (EvalString_0 && EvalString_1) { @@ -1292,7 +1291,6 @@ helpUrl : https://h5mota.com/games/template/_docs/#/event?id=hideFloorImg%ef%bc% default : ["","",""] allFloorIds : ['IdString_0'] colour : this.mapColor -selectPoint : ["EvalString_0", "EvalString_1", "IdString_0"] var floorstr = ''; if (EvalString_0 && EvalString_1) { var pattern1 = MotaActionFunctions.pattern.id; @@ -2445,7 +2443,7 @@ break_s : '跳出当前循环或公共事件' Newline /* break_s -tooltip : break:跳出循环, 如果break事件不在任何循环中被执行,则和exit等价,即会立刻结束当前事件! +tooltip : break:跳出循环或公共事件! helpUrl : https://h5mota.com/games/template/_docs/#/event?id=break%EF%BC%9A%E8%B7%B3%E5%87%BA%E5%BE%AA%E7%8E%AF colour : this.eventColor var code = '{"type": "break"},\n'; @@ -2453,10 +2451,10 @@ return code; */; continue_s - : '继续当前循环' Newline + : '提前结束本轮循环或跳出公共事件' Newline /* continue_s -tooltip : continue:继续执行当前循环的下一轮, 如果continue事件不在任何循环中被执行,则和exit等价,即会立刻结束当前事件! +tooltip : continue:继续执行当前循环的下一轮,或跳出公共事件! helpUrl : https://h5mota.com/games/template/_docs/#/event?id=continue%EF%BC%9A%E7%BB%A7%E7%BB%AD%E6%89%A7%E8%A1%8C%E5%BD%93%E5%89%8D%E5%BE%AA%E7%8E%AF colour : this.eventColor var code = '{"type": "continue"},\n'; diff --git a/_server/MotaActionParser.js b/_server/MotaActionParser.js index 43c59ca1..6f16a939 100644 --- a/_server/MotaActionParser.js +++ b/_server/MotaActionParser.js @@ -1201,6 +1201,8 @@ MotaActionFunctions.IdString_pre = function(IdString){ MotaActionFunctions.PosString_pre = function(PosString){ if (!PosString || /^-?\d+$/.test(PosString)) return PosString; //if (!(MotaActionFunctions.pattern.id.test(PosString)))throw new Error(PosString+'中包含了0-9 a-z A-Z _ 和中文之外的字符,或者是没有以flag: 开头'); + var comma = PosString.indexOf(','); + if (comma >= 0 && PosString.substring(0, comma).indexOf('(') < 0) throw '此处不可写多点坐标'; return '"'+MotaActionFunctions.replaceFromName(PosString)+'"'; } diff --git a/_server/table/comment.js b/_server/table/comment.js index 1531ff7a..c79ee185 100644 --- a/_server/table/comment.js +++ b/_server/table/comment.js @@ -509,7 +509,7 @@ var comment_c456ea59_6018_45ef_8bcc_211a24c627dc = { "ratio": { "_leaf": true, "_type": "textarea", - "_range": "(thiseval==~~thiseval && thiseval>=0)||thiseval==null", + "_range": "thiseval==~~thiseval && thiseval>=0", "_docs": "宝石血瓶效果", "_data": "每一层的宝石/血瓶效果,即获得宝石和血瓶时框内\"ratio\"的值。" } diff --git a/editor-mobile.html b/editor-mobile.html index 19cf4c3c..19b04ef0 100644 --- a/editor-mobile.html +++ b/editor-mobile.html @@ -7,6 +7,7 @@ +