LuckPerms

LuckPerms

41.4k Downloads

'setsuffix' Issue

Cheesearmada opened this issue ยท 6 comments

commented

When executing command with syntax 'meta setsuffix' the command does not remove and then set the new suffix, instead it just stacks on itself.

Luck Perms Version: v5.0.50

Server Version: Spigot-1.14.4

Screen Shot 2020-01-01 at 10 23 52 PM

commented

Seems to be working fine for me.

commented

I provided that as an example of a command we're trying to use. Unfortunately for us, the 'setsuffix' command is performing the same function as the 'addsuffix' command, or at least emulating it. Perhaps I didn't do a good job of describing my situation.

We use a GUI that players can select/purchase a suffix with points. When they click on the suffix they want, the 'lp user %player% meta setsuffix 5000 " &7[&d&lAussie&7]&r" global' command is executed. However, when a player wants to select a new suffix, the 'setsuffix' command doesn't overwrite the old suffix, instead it just adds a suffix, if that makes sense.

commented

The setsuffix command is essentially a simplified version of the addsuffix command with the difference, that the priority should be optional and LP would calculate a own weight to use to display the suffix.

It only replaces suffixes that are the same context as the one you set.

Quote from the command page

This is different from the addsuffix command in that existing suffixes set in the same context are removed when the new suffix is added. Another difference is that the priority argument is optional in the setsuffix command - LuckPerms will determine an appropriate value for the priority when the command is ran.

commented

Does not appear to work for us.

Could us using MySQL have any affect on this? Also we're using your Legacy API Extension tool

  • 'lp user %player% meta setsuffix 5000 " &7[&d&lAussie&7]&r" global'
commented

global is optional btw.

commented

Try removing the global bit at the end of the command - I think that will probably fix your problem.