Skip to content
This repository has been archived by the owner on Apr 3, 2024. It is now read-only.

Conditional: Group

ricochet1k edited this page Feb 28, 2012 · 5 revisions

Syntax: {entity}.group.{groupalias}

Description: Returns true if the specified entity matches the specified group alias. Currently supported Permissions implementations can be found at the [PermissionsManager enum in ExternalPluginManager.java] (https://github.com/ModDamage/ModDamage/blob/master/src/com/ModDamage/ExternalPluginManager.java) in source.

Example:

Damage:  # no friendly fire for elves
    - 'if attacker.group.elves and target.group.elves'
        - '0'  # sets damage to 0
Damage: #Give admins a defensive buff.
    - 'if target.group.Admins': '-2'
Aliases:
    Group:
        administrative:  # this is an alias for any of the three groups below, to save on typing
            - 'moderator'
            - 'admin'
            - 'owner'
Damage:
    - 'if target.group._administrative and !attacker.group._administrative':
        - 'message.attacker.&7BITCH PLEASE'
        - 'attackereffect.hurt': 'damage' # Reflects damage back on attacker
        - '0' # And removes all damage to the target

See also: Hurt, Message, Value Change

Clone this wiki locally