From 65997417aba161d43fba86d7605bef32b167cf92 Mon Sep 17 00:00:00 2001 From: lzr <1838979562@qq.com> Date: Sun, 31 Dec 2023 19:46:51 +0800 Subject: [PATCH] =?UTF-8?q?=E4=B9=90=E5=AD=90=E4=BA=BA=E6=AD=A3=E5=9C=A8?= =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Readme.md | 2 +- js/plugins/YEP_X_SkillCooldowns.js | 31 ++++++++++++++++++++++++++++++ 2 files changed, 32 insertions(+), 1 deletion(-) diff --git a/Readme.md b/Readme.md index cbe0b6a..a90ac20 100644 --- a/Readme.md +++ b/Readme.md @@ -2,7 +2,7 @@ 异常生物见闻录 rpg 第二版 仓库 ## 使用者锁 - +乐子人 ## 使用流程 1. 在你进行你的内容更新之前,先执行一次拉取操作。正常情况下不会提示内容冲突,如果有,则VS code右上角点击文件,选择关闭文件夹。然后再把你本地那个同步文件夹删掉,重新从Github克隆。 diff --git a/js/plugins/YEP_X_SkillCooldowns.js b/js/plugins/YEP_X_SkillCooldowns.js index 2027f6f..be909c1 100644 --- a/js/plugins/YEP_X_SkillCooldowns.js +++ b/js/plugins/YEP_X_SkillCooldowns.js @@ -99,6 +99,17 @@ Yanfly.SCD.version = 1.11; * @default 100 * * @help + * + * 魔改作者: 流逝的岁月 + * 魔改版本: v1.00 + * + * + * 魔改内容: v1.00 使显示冷却回合 的文本内容向上取整 + * + * + * + * + * * ============================================================================ * Introduction * ============================================================================ @@ -272,6 +283,10 @@ Yanfly.SCD.version = 1.11; * * 将这两个标签插入技能的记事框中,为其提供确定预热值的独特方法。 * “warmup”变量确定预热的回合数。 + * + * 插件提供的函数: + * 改变user的指定技能的冷却 + * user.addCooldown(技能ID,冷却改变值); * * ============================================================================ * Yanfly Engine Plugins - Battle Engine Extension - Action Sequence Commands @@ -376,6 +391,11 @@ if (Imported.YEP_SkillCore) { // Parameter Variables //============================================================================= + + var Zzy = Zzy || {}; + Zzy.CXSCD = Zzy.CXSCD || {}; + + Yanfly.Parameters = PluginManager.parameters("YEP_X_SkillCooldowns"); Yanfly.Param = Yanfly.Param || {}; Yanfly.Icon = Yanfly.Icon || {}; @@ -1464,6 +1484,12 @@ if (Imported.YEP_SkillCore) { var value = this._actor.cooldown(skill.id); if (value % 1 !== 0) value = value.toFixed(2); if (value <= 0.009) value = 0.01; + + //---魔改--- v1.00 修改数据向上取整 + value = value.ceil(value); + + + var text = fmt.format(Yanfly.Util.toGroup(value)); this.contents.fontSize = Yanfly.Param.CDFontSize; this.drawText(text, wx, wy, dw, "right"); @@ -1483,6 +1509,11 @@ if (Imported.YEP_SkillCore) { var value = this._actor.warmup(skill.id); if (value % 1 !== 0) value = value.toFixed(2); if (value <= 0.009) value = 0.01; + + //---魔改--- v1.00 修改数据向上取整 + value = value.ceil(value); + + var text = fmt.format(Yanfly.Util.toGroup(value)); this.contents.fontSize = Yanfly.Param.WUFontSize; this.drawText(text, wx, wy, dw, "right");