1. Animals
  2. Abilities
  3. Conditions
  4. Tool/Weapon
  5. Equipped
  6. Food/Medicine
  7. Items
  8. Attributes
  9. Creatures
  10. Blocks
  11. Props
  12. API Types
  13. API Functions


boolean LT_entity_inflict(number attacker,number target,number condition)

numberattacker The index of entity character doing the inflicting
numbertarget The index of entity character being inflicted
numbercondition Condition ID to inflict

SERVER This has no effect if performed on the client (but will work in single player)

Attempts to inflict a condition on a character. Provide the entity index numbers for attacker and target, not the entity tables themselves. Both are needed since the condition is inflicted as though the attacker did it. If you don't want to provide an attacker, you can put the same entity index as target for self infliction. This can fail if the target is immune to the condition, or isn't actually a character entity. Strength of inflicted condition is calculated between attacker and target, so both are required. Provide the condition ID of the condition to inflict, you can look those up here.