Represents a mod in the game.

You can get a mod by using loadedMods.botania or loadedMods["botania"]

It might be required for you to import the package if you encounter any issues (like casting an Array), so better be safe than sorry and add the import at the very top of the file.

ZenScript
Copy
import crafttweaker.api.mod.Mod;

Name: displayName

Gets the display name of this mod.

Returns: The display name of this mod.
Return Type: string

ZenScript
Copy
// Mod.displayName() as string

loadedMods.botania.displayName();

Name: getAttributes

Gets the attributes that are registered under this mod's ID.

Returns: A list of attributes that were registered under this mod's ID.
Return Type: Collection<Attribute>

ZenScript
Copy
// Mod.getAttributes() as Collection<Attribute>

loadedMods.botania.getAttributes();

Name: getBlocks

Gets the blocks that are registered under this mod's ID.

Returns: A list of blocks that were registered under this mod's ID.
Return Type: Collection<Block>

ZenScript
Copy
// Mod.getBlocks() as Collection<Block>

loadedMods.botania.getBlocks();

Name: getEnchantments

Gets the enchantments that are registered under this mod's ID.

Returns: A list of enchantments that were registered under this mod's ID.
Return Type: Collection<Enchantment>

ZenScript
Copy
// Mod.getEnchantments() as Collection<Enchantment>

loadedMods.botania.getEnchantments();

Name: getFluids

Gets the fluids that are registered under this mod's ID.

Returns: A list of fluids that were registered under this mod's ID.
Return Type: Collection<Fluid>

ZenScript
Copy
// Mod.getFluids() as Collection<Fluid>

loadedMods.botania.getFluids();

Name: getItemStacks

Gets the ItemStacks that are registered under this mod's ID.

Returns: A list of ItemStacks that were registered under this mod's ID.
Return Type: Collection<IItemStack>

ZenScript
Copy
// Mod.getItemStacks() as Collection<IItemStack>

loadedMods.botania.getItemStacks();

Name: getItems

Gets the items that are registered under this mod's ID.

Returns: A list of items that were registered under this mod's ID.
Return Type: Collection<ItemDefinition>

ZenScript
Copy
// Mod.getItems() as Collection<ItemDefinition>

loadedMods.botania.getItems();

Name: getMobEffects

Gets the mob effects that are registered under this mod's ID.

Returns: A list of mob effects that were registered under this mod's ID.
Return Type: Collection<MobEffect>

ZenScript
Copy
// Mod.getMobEffects() as Collection<MobEffect>

loadedMods.botania.getMobEffects();

Name: getPotions

Gets the potions that are registered under this mod's ID.

Returns: A list of potions that were registered under this mod's ID.
Return Type: Collection<Potion>

ZenScript
Copy
// Mod.getPotions() as Collection<Potion>

loadedMods.botania.getPotions();

Name: getSoundEvents

Gets the sound events that are registered under this mod's ID.

Returns: A list of sound events that were registered under this mod's ID.
Return Type: Collection<SoundEvent>

ZenScript
Copy
// Mod.getSoundEvents() as Collection<SoundEvent>

loadedMods.botania.getSoundEvents();

Link to getVillagerProfessions

Name: getVillagerProfessions

Gets the villager professions that are registered under this mod's ID.

Returns: A list of villager professions that were registered under this mod's ID.
Return Type: Collection<VillagerProfession>

ZenScript
Copy
// Mod.getVillagerProfessions() as Collection<VillagerProfession>

loadedMods.botania.getVillagerProfessions();

Name: id

Gets the id (namespace) of this mod.

Returns: The id (namespace) of this mod.
Return Type: string

ZenScript
Copy
// Mod.id() as string

loadedMods.botania.id();

Name: version

Gets the version of this mod.

Returns: The version of this mod.
Return Type: string

ZenScript
Copy
// Mod.version() as string

loadedMods.botania.version();
名称类型可获得可设置描述
名称
attributes
类型
Collection<Attribute>
可获得
true
可设置
false
描述
Gets the attributes that are registered under this mod's ID.
名称
blocks
类型
Collection<Block>
可获得
true
可设置
false
描述
Gets the blocks that are registered under this mod's ID.
名称
displayName
类型
string
可获得
true
可设置
false
描述
Gets the display name of this mod.
名称
enchantments
类型
Collection<Enchantment>
可获得
true
可设置
false
描述
Gets the enchantments that are registered under this mod's ID.
名称
fluids
类型
Collection<Fluid>
可获得
true
可设置
false
描述
Gets the fluids that are registered under this mod's ID.
名称
id
类型
string
可获得
true
可设置
false
描述
Gets the id (namespace) of this mod.
名称
itemStacks
类型
Collection<IItemStack>
可获得
true
可设置
false
描述
Gets the ItemStacks that are registered under this mod's ID.
名称
items
类型
Collection<ItemDefinition>
可获得
true
可设置
false
描述
Gets the items that are registered under this mod's ID.
名称
mobEffects
类型
Collection<MobEffect>
可获得
true
可设置
false
描述
Gets the mob effects that are registered under this mod's ID.
名称
potions
类型
Collection<Potion>
可获得
true
可设置
false
描述
Gets the potions that are registered under this mod's ID.
名称
soundEvents
类型
Collection<SoundEvent>
可获得
true
可设置
false
描述
Gets the sound events that are registered under this mod's ID.
名称
version
类型
string
可获得
true
可设置
false
描述
Gets the version of this mod.
名称
villagerProfessions
类型
Collection<VillagerProfession>
可获得
true
可设置
false
描述
Gets the villager professions that are registered under this mod's ID.