Skip to main content

living_loot_equipment

Function living_loot_equipment 

Source
pub(crate) fn living_loot_equipment<E: LivingEntity + ?Sized>(
    entity: &E,
) -> EntityEquipmentSlots
Expand description

Clones every equipment slot of entity so loot predicates can read it without holding the equipment lock while the table rolls.

Locks the entity’s equipment (a player’s inventory), so callers must not already hold it.