Skip to main content

AddDamageRule

Sets the damage rule for a player.

Syntaxโ€‹

AddDamageRule mode @players_affected multiplier "remove_id"? update?

Argumentsโ€‹

NameRequiredTypeDescription
modeYesOne of the following options:
> attacker
> receiver
> reciever
Indicates whether the damage rule will be applied on all damage dealt by the attacker or on all damage received by the receiver.
players affectedYesPlayer variable (e.g. @all, @classDPlayers)
multiplierYesAny number
remove idNoAny text e.g. "Hello, World!"The ID of the damage rule. This is to identify this specific damage rule if you later want to remove SPECIFICALLY it later. There can be multiple rules with the same ID.
updateNobool (true or false) valueWhether the rule should check for any changes regarding the 'players affected' argument. E.g. when you use 'players affected' = ClassD and 'update' = false, then the damage rule will NOT update when player roles change, meaning that when some ClassD becomes a Guard, their damage rule will STILL apply, even though they are no longer ClassD.

On a running serverโ€‹

Use serhelp AddDamageRule to inspect the reference generated by your installed SER version.