Skip to content
MaxDikiy edited this page Jul 24, 2017 · 1 revision

This activator works when the player is exposed to some kind of damage.

To create this activator, use the command:

/react add DAMAGE <ActivatorId> [source:<BLOCK/ENTITY/OTHER/ANY>] [cause:<type>]

Temporary placeholders operating in this activator:

Placeholder Description
%damage% Damage the will deal to mob. You can modify this temporary variable using VAR_TEMP_SET action to change value of player damage
%cause% Damage cause
%source% Damage source

Examples

  1. To forbid to damage the player in any way:
    /react add DAMAGE d
    /react add d a CANCEL_EVENT true
    or
DAMAGE:
  d:
    cause: ANY
    source: ANY
    flags: []
    actions:
    - 'MESSAGE=Damage: &c%damage%'
    - 'MESSAGE=Cause: &c%cause%'
    - 'MESSAGE=Source: &c%source%'
    - cancel_event=true
    reactions: []
Clone this wiki locally