Lava Java
Lava Java 的 Lava Javas 将温暖你焦黑的骨骼!每一杯都是独特风味的旋律,确保你能以最佳状态面对余下的一天。Lava Javas 起价仅 4 个金粒,价格在任何标准下都可谓亲民。我们友好的员工始终致力于提升自我,因此每次光顾时,他们都会为你准备全新且令人兴奋的 Lava Javas 供你尝试。请将所有投诉和意见转达给分店经理。
Lava Java 为下界添加了一个结构:Lava Java 咖啡馆。在咖啡馆内,有一对友好的咖啡师,他们会用金粒向你出售零食和 Lava Javas。每种 Lava Java 都会根据饮料的风味和新鲜度提供一项或多项增益效果。随着你与特定咖啡师的交易增多,该咖啡师的技术会变得更加娴熟,能够一次性售出更多饮品并制作更复杂的混合饮品。
数据包
Lava Java 使用数据包来决定饮品可以拥有的风味。它会查找 data/lavajava/lava_java_flavor 目录下的 json 文件。其格式如下:
{
"flavorID": "spellbound:bubbly",
"statusID": "spellbound:shielded",
"isDrawback": false,
"duration": 7200,
"magnitude": 4,
"weight": 30,
"value": 15,
"namePriority": 0,
"exclusions": [
"spellbound:extra_bubbly",
"spellbound:very_bubbly"
]
}
flavorID: 你定义的风味的 ID。这是必填项。与 json 文件的名称不同,此 ID 必须是唯一的,否则可能会与其他风味发生冲突。
statusID: 你的风味所提供的状态效果的 ID。这是必填项。
isDrawback: 决定该风味是增加还是减少 Lava Java 的成本。默认为 false。在未来,它可能会影响选择该风味的条件。
duration: 风味效果持续的刻数。这是必填项,必须为正整数。
magnitude: 决定效果的强度等级。这是可选的,但建议使用。如果提供,必须为非负整数。默认为 0。请注意,内部的效果强度等级比游戏中显示的要低一级。例如,力量 II 实际上对应的是 magnitude 1。
weight: 决定该风味的稀有程度。这是必填项,必须为正整数。风味生成过程可以看作是从盒子中抽取奖券的抽奖机制,这里的数值代表指向该风味的奖券数量(如果被选中)。45 用于常见风味(如 Sweet 或 Creamy),30 用于既非常见也非稀有的风味(如 Spicy),而 10 则用于稀有风味(如 Thick 或 Filling)。通常情况下,风味的进阶版本(如 Extra Spicy)的稀有度应是其基础版本的 5 倍。
value: 决定该风味对价格的影响程度。这是必填项,必须为正整数。仅包含你定义的风味的 Lava Java 的价格大约是该数值的一半。如果该风味为负面效果,则决定价格降低的金额。通常情况下,风味的进阶版本(如 Very Creamy)的价格应为其基础版本的 2 倍。
namePriority: 目前无效。这是可选的。如果提供,必须为整数。默认值为 0。一旦实现,它将决定风味在 Lava Java 名称中的排列顺序。优先级较高的风味将排在饮品名称的后面(即生成 “Sweet Spicy Lava Java” 而不是 “Spicy Sweet Lava Java”)。
exclusions: 一个风味 ID 列表,防止该风味与列表中列出的风味共存。这是可选的。如果该风味被选中但排他性风味优先被选中,或者排他性风味被选中但它是后选中的,那么第二个风味将被重新随机抽取。_这些风味无需实际存在。_这允许你排除来自其他模组的某些风味,即使你没有将该模组作为依赖项。
创建好你的风味后,在语言文件中添加一行,格式为 "flavor.spellbound.bubbly": "Bubbly",,以设置该风味的显示名称。
Lava Java
Lava Java's Lava Javas will warm your blackened bones! Each cup is a melody of unique flavors that will ensure you are able to face the rest of your day. With Lava Javas starting at only 4 gold nuggets, our prices are affordable by any standard. Our friendly staff are always working to improve, so every time you visit they will have new and exciting Lava Javas waiting for you to try. Please forward all complains and concerns to the branch manager.
Lava Java adds a structure to the Nether: the Lava Java Café. Within the café is a pair of friendly baristas who will sell you snacks and Lava Javas in exchange for gold nuggets. Each Lava Java will grant one or more buffs based on the drink's flavor and freshness. As you trade with a particular barista it will become more skilled, selling more drinks at once and making more complex brews.
Data Packs
Lava Java uses datapacks to determine the flavors that drinks can have. It looks for json files under data/lavajava/lava_java_flavor. They are formatted like so:
{
"flavorID": "spellbound:bubbly",
"statusID": "spellbound:shielded",
"isDrawback": false,
"duration": 7200,
"magnitude": 4,
"weight": 30,
"value": 15,
"namePriority": 0,
"exclusions": [
"spellbound:extra_bubbly",
"spellbound:very_bubbly"
]
}
flavorID: the ID of your flavor. This is mandatory. Unlike the name of the json file, this must be unique. Otherwise it may conflict with other flavors.
statusID: the ID of the status effect your flavor provides. This is mandatory.
isDrawback: determines if the flavor decreases or increases the cost of a Lava Java. Defaults to false. In the future, may effect the conditions under which it can be selected.
duration: how many ticks the flavor's effect will last. This is mandatory, and must be a positive integer.
magnitude: determines the magnitude of the effect. This is optional, but recommended. If provided, must be a non-negative integer. Defaults to 0. Keep in mind that internally effect magnitudes are one lower than they are displayed in game. Strength II is actually magnitude 1, for example.
weight: determines how common the flavor is. This is mandatory, and must be a positive integer. Flavor generation may be seen like a raffle where tickets are pulled from a box, and this is how many tickets point to this flavor if chosen. 45 is for common flavors like Sweet or Creamy, 30 is for flavors that are neither common nor uncommon like Spicy, and 10 is for rare flavors like Thick or Filling. Generally, superior versions of a flavor (such as Extra Spicy) should be 5 times as rare as their lesser variants.
value: how much the flavor influences prices. This is mandatory, and must be a positive integer. A Lava Java with just your flavor will cost about one quarter this number. If the flavor is negative, it instead determines how much the price is reduced. Generally, superior versions of a flavor (such as Very Creamy) should cost twice as much as their lesser variants.
namePriority: currently does nothing. This is optional. If provided, must be an integer. Default value is 0. Once implemented, it will determine the order that flavors are listed in a Lava Java's name. Higher priorities will be listed later in the drinks name (a Sweet Spicy Lava Java rather than a Spicy Sweet Lava Java)
exclusions: a list of flavorIDs that prevents this flavor from co-existing with the listed flavors. This is optional. If it would be selected but an excluded flavor was first, or if an excluded flavor has been selected but it had been selected first, than the second flavor will be rerolled. These flavors do not need to exist. This allows you to exclude flavors that come from other mods, even if you do not use that mod as a dependency.
Once you have created your flavor, add a line to your language file in the format "flavor.spellbound.bubbly": "Bubbly", to set the display name of the flavor.
评论 0
登录后参与评分
还没有评论,来抢沙发吧