[Cobblemon] TrainerAttributesLib 图标

[Cobblemon] TrainerAttributesLib

作者:rebot | 分类:模组

价格:0 墨喵币 下载量:0 点赞:0 版本 1.7.3-1.0.2
本资源为搬运资源,原资源地址: https://modrinth.com/mod/trainerattributeslib
资源信息

Minecraft 版本: 1.21.1

平台: fabric

标签: library

资源介绍

Integrates Minecraft's attribute system with Cobblemon.

Things such as catch chance, shiny chance, and experience earned per battle can be modified.

Mostly intended for use with Accessories or Curios, though the attributes do apply when on pieces of armor. (but not tools)

If I ever truly decide to stop being lazy I'll port it over to forge as well.

Free for use whereva.

Features

Current Attributes Supported:

  • Pokemon Experience Boost (+ Various types)
  • Catch Chance Boost (+ Various Types)
  • Shiny Chance Boost (+ Various Types)
  • Hidden Ability Chance Boost (+ Various Types)
  • Crit Catch Chance Boost (+ Various types)
  • Spawn Chance Boost (+ Various Types)
  • Bonus IVs (+ Various Types / For Specific Stats)

Example

class MudkipCharm() : AccessoryItem(
    Item.Settings().component(
        DataComponentTypes.ATTRIBUTE_MODIFIERS as ComponentType<AttributeModifiersComponent>,
        AttributeModifiersComponent.builder()
            .add(
                Registries.ATTRIBUTE.getEntry(TrainerAttributes.TYPED_SPAWN_CHANCE_ATTRIBUTE.getAttributeOfType(
                    ElementalTypes.FIRE
                )),
                EntityAttributeModifier(
                    TrainerAttributes.TYPED_SPAWN_CHANCE_ATTRIBUTE.getIdentifierOfTypedAttribute(ElementalTypes.FIRE),
                    5.50,
                    EntityAttributeModifier.Operation.ADD_MULTIPLIED_BASE
                ),
                AttributeModifierSlot.ANY
            )
            .add(
                Registries.ATTRIBUTE.getEntry(TrainerAttributes.TYPED_BONUS_IVS_ATTRIBUTE.getAttributeOfType(
                    ElementalTypes.WATER
                )),
                EntityAttributeModifier(
                    TrainerAttributes.TYPED_BONUS_IVS_ATTRIBUTE.getIdentifierOfTypedAttribute(ElementalTypes.WATER),
                    5.0,
                    EntityAttributeModifier.Operation.ADD_VALUE
                ),
                AttributeModifierSlot.ANY
            )
            .add(
                Registries.ATTRIBUTE.getEntry(TrainerAttributes.STAT_BONUS_IVS_ATTRIBUTE.getAttributeOfStat(Stats.HP)),
                EntityAttributeModifier(
                    TrainerAttributes.STAT_BONUS_IVS_ATTRIBUTE.getIdentifierOfStatAttribute(Stats.HP),
                    5.0,
                    EntityAttributeModifier.Operation.ADD_VALUE
                ),
                AttributeModifierSlot.ANY
            )
            .add(
                Registries.ATTRIBUTE.getEntry(TrainerAttributes.BONUS_IVS_ATTRIBUTE),
                EntityAttributeModifier(
                    TrainerAttributesLib.getIdentifier("bonus_ivs"),
                    5.0,
                    EntityAttributeModifier.Operation.ADD_VALUE
                ),
                AttributeModifierSlot.ANY
            )
            .add(
                Registries.ATTRIBUTE.getEntry(TrainerAttributes.CATCH_CHANCE_BOOST_ATTRIBUTE),
                EntityAttributeModifier(
                    TrainerAttributesLib.getIdentifier("catch_chance_boost"),
                    0.05,
                    EntityAttributeModifier.Operation.ADD_MULTIPLIED_BASE
                ),
                AttributeModifierSlot.ANY
            )
            .add(
                Registries.ATTRIBUTE.getEntry(
                    TrainerAttributes.TYPED_CATCH_CHANCE_BOOST_ATTRIBUTE.getAttributeOfType(ElementalTypes.WATER)
                ),
                EntityAttributeModifier(
                    TrainerAttributes.TYPED_CATCH_CHANCE_BOOST_ATTRIBUTE.getIdentifierOfTypedAttribute(ElementalTypes.WATER),
                    0.10,
                    EntityAttributeModifier.Operation.ADD_MULTIPLIED_BASE
                ),
                AttributeModifierSlot.ANY
            )
            .build()
    )
) {
}
📥 下载与版本
评论(0)
登录 后发表评论。

暂无评论,抢个沙发吧~

举报此资源

请登录后举报

🔥 相关推荐
KubeJS Thermal

价格:0 墨喵币
下载量:0

查看详情
Vampirism

价格:0 墨喵币
下载量:0

查看详情
Celestial Skies

价格:0 墨喵币
下载量:0

查看详情
Better Moss

价格:0 墨喵币
下载量:0

查看详情