星露谷物语v0.7.02026年10月11日 更新

Buff Framework(增益效果框架)

开放游戏的增益效果系统,可依据 Content Patcher 条件灵活触发增益,也可供 SMAPI 模组访问其字典。需要 SMAPI;提供 Generic Mod Config Menu 游戏内设置界面。

Buff Framework(增益效果框架)

本模组开放游戏的增益效果系统,允许根据 Content Patcher 条件灵活触发增益。

使用示例

以下 Content Patcher 配置会在玩家穿着 Midnight Dog Jacket 时应用 Squid Ink Ravioli 增益:

{
  "Format": "1.28.4",
  "Changes": [
    {
      "Action": "EditData",
      "Target": "aedenthorn.BuffFramework/dictionary",
      "LogName": "",
      "Entries": {
        "aedenthorn.JacketBuff": {
          "shirt": "Midnight Dog Jacket",
          "which": 28,
          "source": "aedenthorn.MidnightDogJacketBuff",
          "displaySource": "Midnight Dog Jacket Buff"
        }
      }
    }
  ]
}

可用字段模板

{
  "Format": "1.28.4",
  "Changes": [
    {
      "Action": "EditData",
      "Target": "aedenthorn.BuffFramework/dictionary",
      "LogName": "",
      "Entries": {
        "aedenthorn.BuffTestCP": {
          "which": -1,
          "sheetIndex": -1,
          "glow": {
            "R": 255,
            "G": 0,
            "B": 255,
            "A": 255
          },
          "consume": null,
          "duration": null,
          "hat": null,
          "shirt": null,
          "pants": null,
          "boots": null,
          "ring": null,
          "farming": null,
          "fishing": null,
          "mining": null,
          "digging": null,
          "luck": null,
          "foraging": null,
          "crafting": null,
          "maxStamina": null,
          "magneticRadius": null,
          "speed": 5,
          "defense": null,
          "attack": null,
          "healthRegen": null,
          "staminaRegen": null,
          "source": "aedenthorn.BuffTestCP",
          "displaySource": "Test Buff",
          "description": "Speedy!",
          "buffId": 42424201,
          "glowRate": 0.1,
          "sound": "yoba",
          "texturePath": null,
          "textureX": null,
          "textureY": null,
          "textureWidth": null,
          "textureHeight": null,
          "textureScale": null
        }
      }
    }
  ]
}

内置增益

which 可设为以下游戏内置增益:

  • 6:饱腹
  • 7:解渴
  • 12:灼伤
  • 13:黏液
  • 14:厄运
  • 17:醉酒
  • 18:惊吓
  • 19:冰冻
  • 20:战士能量
  • 21:无敌
  • 22:肾上腺素激增
  • 23:大蒜油
  • 24:怪物麝香
  • 25:恶心
  • 26:黑暗
  • 27:虚弱
  • 28:鱿鱼墨汁馄饨

如果 which 设为 -1 或省略,则不使用内置增益列表,必须设置 buffId。如果设置了 which,则省略 buffId。

sheetIndex 用于从游戏内置的 Tilesheets/BuffIcons 图标列表中选择增益图标。

无论是否设置 which,都可以调整示例中列出的增益属性。省略或设为 null 的属性不会被调整。若 glow 设为 255 255 255 255,则会禁用辉光。触发增益时会播放 sound 指定的声音。texturePath 可用于自定义增益图标,使用 Content Patcher 将其指向模组图标。

触发条件

  • consume:设置可食用物品的名称,在玩家吃下该物品时触发增益。若使用的不是上述内置增益,必须通过 duration 手动设置持续时间(秒)。
  • hat、shirt、pants、boots、ring:可设置物品名称,使增益仅在玩家穿戴指定物品时生效。

使用此框架的模组示例:After Midnight Speed Buff。SMAPI 模组也可以访问本模组的字典,示例:Birthday Buff。

安装与技术信息

需要 SMAPI。本模组提供 Generic Mod Config Menu 界面,可在游戏中修改设置。

源代码:https://github.com/aedenthorn/StardewValleyMods

作者的 Discord:https://discord.gg/bs6zHuj

作者的星露谷物语模组列表:https://www.nexusmods.com/stardewvalley/articles/895

来源与文件

  • 原作者:aedenthorn
  • 原项目:Buff Framework
  • 文件:Buff Framework(ID:141001)

文件说明

Changes:

Update for 1.6

前往 N 网打开所选文件。安装与下载要求以原作者及平台说明为准。

<!-- aoe-mods-source:nexusmods:stardewvalley:17746 -->

下载模块

共 1 个来源
立即下载推荐来源
前往下载