DamageSource - Create (Expression) — SkBee
Addon: SkBee · Category: Expression · Since: 3.3.0
Syntax
[[a] new] damage source (of|from) %damagetype% [caused by %-entity%] [directly (by|from) %-entity%] [at %-location%]Description
Create a new damage source which includes a damage type and some optional values. Optional Values: `caused by %entity%` = The entity that caused the damage. `directly by %entity%` = The entity that directly inflicted the damage. `at %location%` = The source of the damage.
Examples
set {_source} to damage source from arrow directly by (random element of all entities)
set {_source} to damage source of dragon breath
set {_source} to damage source of magic
set {_source} to damage source of mob_attack_no_aggro caused by target entity of player
damage player by 100 with {_source}