Damage

Bi-entity Action Type

Applies damage to the target entity as if the actor entity has attacked it.

Type ID: origins:damage

Fields

Field Type Default Description
amount Float The amount of damage to deal.
source Damage Source DEPRECATED Use damage_type instead. More information here.
damage_type Identifier The damage type to be used. Controls e.g. the death message, invulnerabilities (e.g. towards fire), or whether armor is taken into account.

Examples

"bientity_action": {
    "type": "origins:damage",
    "amount": 10,
    "damage_type": "minecraft:cramming"
}

This example will deal 5 hearts of cramming damage to the target as if the actor has hit them, and that, if killed, will display a "<targetName> was squashed by <actorName>", where <targetName> is the name of the target and <actorName> is the name of the actor.