#Can I get the server rank for someone who isn't online using their userid?

1 messages · Page 1 of 1 (latest)

modern hemlock
#

I specifically need their rank colour for scpdiscord message styling.

waxen urchin
#

What rank? Like if they are admin/moderator?

modern hemlock
#

yes

waxen urchin
#

PermissionsHandler.Members

#
if (!ServerStatic.PermissionsHandler.Members.TryGetValue(playerStringId, out string group))
  return string.Empty;
if (!ServerStatic.PermissionsHandler.Groups.TryGetValue(group, out var userGroup))
 return string.Empty;
return userGroup.BadgeColor
modern hemlock
#

where do I get the permissions handler from? it is not static and doesnt appear to have a getter for its singleton

waxen urchin
#

ServerStatic.PermissionsHandler

modern hemlock
#

thanks, gonna try it now

modern hemlock
#

it works, thanks!

#

although I also realised that users who get their ranks from scpdiscord rather than the game obviously wont show up there so gonna have to make another system to get them

#

hate it when you think youre done but theres a whole other issue you just didnt think about

waxen urchin
#

it loading from the yaml config

modern hemlock
#

yeah I know, and I need to check that too for players that arent set by scpdiscord