Closed williambl closed 2 years ago
It may be worth removing the limitation that only one role can be selected at once, so that the example of @a[player_role=mod, player_role=builder]
given in #40 can be done.
This would also eliminate about half of the code of this PR, which would be good.
Although, entity selector options work with and
, not or
, so that example would only select builders who are also mods. Perhaps some custom syntax will be required, such as @a[role=mod|builder]
.
I think that using the same behavior as the team
entity selector option would make the most sense.
That's current behaviour, as far as I can tell.
This PR adds a
role
entity selector option, as asked for in #40.Here is an example of usage:
Negation is supported, too:
Multiple negated selections can be used; only one non-negated selection can be used.
Unfortunately, entity selector options are not synced to the client, so a vanilla client will see them as invalid:
However, they still work fine when executed.