Package hiiragi283.core.api.item.alchemy
Object HTPotionHelper
-
- All Implemented Interfaces:
public class HTPotionHelper- Since:
0.3.0
Hiiragi Tsubasa
-
-
Field Summary
Fields Modifier and Type Field Description public final static HTPotionHelperINSTANCE
-
Method Summary
Modifier and Type Method Description final static PotionContentsgetPotion(DataComponentHolder holder)指定したholderからPotionContentsを取得します。 final static StringgetPotionName(DataComponentHolder holder, HTBottleType bottleType)指定したholderとbottleTypeからポーションの翻訳キーを取得します。 final static ItemStackcreatePotion(ItemLike item, Holder<Potion> potion, Integer count)指定した引数からポーションのItemStackを作成します。 final static ItemStackcreatePotion(ItemLike item, PotionContents contents, Integer count)指定した引数からポーションのItemStackを作成します。 -
-
Method Detail
-
getPotion
final static PotionContents getPotion(DataComponentHolder holder)
指定したholderからPotionContentsを取得します。
- Returns:
値を保持していない場合はPotionContents.EMPTY
- Since:
0.10.0
-
getPotionName
final static String getPotionName(DataComponentHolder holder, HTBottleType bottleType)
指定したholderとbottleTypeからポーションの翻訳キーを取得します。
- Since:
0.10.0
-
createPotion
final static ItemStack createPotion(ItemLike item, Holder<Potion> potion, Integer count)
指定した引数からポーションのItemStackを作成します。
- Parameters:
item- アイテムの種類potion- ポーションの中身count- ItemStackの個数
-
createPotion
final static ItemStack createPotion(ItemLike item, PotionContents contents, Integer count)
指定した引数からポーションのItemStackを作成します。
- Parameters:
item- アイテムの種類contents- ポーションの中身count- ItemStackの個数
-
-
-
-