From 84729269647d924cd10729405ec457b94a603cf8 Mon Sep 17 00:00:00 2001 From: Salted <44394537+xian18@users.noreply.github.com> Date: Sun, 24 Jul 2022 12:45:54 +0800 Subject: [PATCH] add Test_Quests,json --- Readme.md | 4 ++-- data/Test_Quests.json | 1 + js/plugins/SF_Core.js | 8 +++++--- js/plugins/SF_MessageBusts.js | 21 ++++++++++++++++----- 4 files changed, 24 insertions(+), 10 deletions(-) create mode 100644 data/Test_Quests.json diff --git a/Readme.md b/Readme.md index 6fb49db..5036028 100644 --- a/Readme.md +++ b/Readme.md @@ -23,5 +23,5 @@ ## 更新记录 - -2022/7/23面具;写入南宫三八技能,优化旧技能并整理装备类型 \ No newline at end of file +- **2022/7/24**;**咸鱼**;添加`Test_Quests.json`来能启动测试。 +- 2022/7/23面具;写入南宫三八技能,优化旧技能并整理装备类型 \ No newline at end of file diff --git a/data/Test_Quests.json b/data/Test_Quests.json new file mode 100644 index 0000000..0637a08 --- /dev/null +++ b/data/Test_Quests.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/js/plugins/SF_Core.js b/js/plugins/SF_Core.js index f0f570d..5c578c8 100644 --- a/js/plugins/SF_Core.js +++ b/js/plugins/SF_Core.js @@ -385,11 +385,11 @@ var SF_Plugins = SF_Plugins || {}; } SF_Core.Utils.isAndroid = function () { - return !!window.FileUtils && !!window.UpdateUtils && !SF_AutoUpdate.isPC(); + return !!window.FileUtils && !SF_Core.Utils.isPC(); } SF_Core.Utils.isWeb = function () { - return !SF_AutoUpdate.isPC() && !SF_AutoUpdate.isAndroid(); + return !SF_Core.Utils.isPC() && !SF_Core.Utils.isAndroid(); } //============================================================================= @@ -628,7 +628,9 @@ var SF_Plugins = SF_Plugins || {}; if (SF_Core.Utils.isAndroid()) { var FileUtils_List = FileUtils.list; - FileUtils.list = function () { } + FileUtils.list = function (name) { + return JsonEx.parse(FileUtils_List.call(this, arguments)); + } } })(); diff --git a/js/plugins/SF_MessageBusts.js b/js/plugins/SF_MessageBusts.js index 9c7874f..b54b170 100644 --- a/js/plugins/SF_MessageBusts.js +++ b/js/plugins/SF_MessageBusts.js @@ -9,8 +9,7 @@ Imported.SF_MessageBusts = true; var SF_Plugins = SF_Plugins || {}; //============================================================================= -/** - /*: +/*: * * @plugindesc Message Busts * @author Salted Fish @@ -28,8 +27,20 @@ var SF_Plugins = SF_Plugins || {}; * * 举例:如果在“显示文本”的命令中选择脸图的文件为"Actor1"的第二个图, * 那么这个插件就会使用 img/faces/large/Actor1_2.png 这张图片作为大号的脸图。 + * 如果不存在,则会使用默认的脸图。 * - * @param scanFiles - * @desc 扫描本地文件夹,生成对应的 + * @requiredAssets data/FaceLarge.json + * @param ScanFiles + * @text 启动时生成数据文件 + * @desc 扫描本地文件夹,生成对应的json文件,只对在nwjs中运行的时候生效。 + * @type boolean + * @on 生成 + * @off 不生成 * - */ \ No newline at end of file + */ + +let SF_MessageBusts = {}; +SF_Plugins.SF_MessageBusts = SF_MessageBusts; + +SF_MessageBusts.Parameters = PluginManager.parameters('SF_MessageBusts'); +SF_MessageBusts.ScanFiles = SF_MessageBusts.Parameters['ScanFiles'].lower() \ No newline at end of file