tModLoader v2025.01
A mod to make and play Terraria mods
All Classes Namespaces Functions Variables Enumerations Enumerator Properties Events Pages
ItemLoot Struct Reference

Provides access to ItemDropDatabase's methods specific to this item type. More...

Inherits ILoot.

Public Member Functions

 ItemLoot (int itemType, ItemDropDatabase itemDropDatabase)
 
IItemDropRule Add (IItemDropRule entry)
 
List< IItemDropRuleGet (bool includeGlobalDrops=true)
 
IItemDropRule Remove (IItemDropRule entry)
 Removes a specific IItemDropRule from this item type. Note that entry must be an existing IItemDropRule instance retrieved from Get(bool), not a newly created instance. More...
 
void RemoveWhere (Predicate< IItemDropRule > predicate, bool includeGlobalDrops=true)
 
IItemDropRule Add (IItemDropRule entry)
 
List< IItemDropRuleGet (bool includeGlobalDrops=true)
 
IItemDropRule Remove (IItemDropRule entry)
 
void RemoveWhere (Predicate< IItemDropRule > predicate, bool includeGlobalDrops=true)
 

Detailed Description

Provides access to ItemDropDatabase's methods specific to this item type.

Member Function Documentation

◆ Add()

IItemDropRule ItemLoot.Add ( IItemDropRule  entry)

Implements ILoot.

◆ Get()

List< IItemDropRule > ItemLoot.Get ( bool  includeGlobalDrops = true)

Parameters
includeGlobalDropsUnused

Implements ILoot.

◆ Remove()

IItemDropRule ItemLoot.Remove ( IItemDropRule  entry)

Removes a specific IItemDropRule from this item type. Note that entry must be an existing IItemDropRule instance retrieved from Get(bool), not a newly created instance.

Implements ILoot.

◆ RemoveWhere()

void ItemLoot.RemoveWhere ( Predicate< IItemDropRule predicate,
bool  includeGlobalDrops = true 
)

Implements ILoot.