Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add /listranked #131

Open
KarlOfDuty opened this issue Feb 4, 2024 · 7 comments
Open

Add /listranked #131

KarlOfDuty opened this issue Feb 4, 2024 · 7 comments

Comments

@KarlOfDuty
Copy link
Owner

KarlOfDuty commented Feb 4, 2024

Same as /list but only showing online users who have server roles.

Closes #85

@KarlOfDuty KarlOfDuty added this to the 3.2.0 milestone Feb 4, 2024
@KarlOfDuty
Copy link
Owner Author

Blocked by northwood-studios/NwPluginAPI#240

@KarlOfDuty KarlOfDuty removed this from the 3.2.0 milestone Feb 7, 2024
@TiBarification
Copy link

Is it possible to use Reflection to handle it ?

@KarlOfDuty
Copy link
Owner Author

It is, but I don't want to resort to such hacks. I want to rely on what is officially provided by the modding api.

@TiBarification
Copy link

Another approach to go through

var permissionHandler = ServerStatic.GetPermissionsHandler();
if (permissionHandler != null)
{
				var userGroup = permissionHandler.GetUserGroup(player.UserId);
				// ...
}

@KarlOfDuty
Copy link
Owner Author

It was some time ago now but im pretty sure I tried that and it didnt work.

@TiBarification
Copy link

Anyway it is requires to go through iteration instead of direct calling object, and thats not nice.

@KarlOfDuty
Copy link
Owner Author

Whoops didnt mean to delete that comment, but basically, im sick so cant verify today but im pretty sure it always returned null or an empty object.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants