EcoModKit icon indicating copy to clipboard operation
EcoModKit copied to clipboard

Add Admin added/removed or Permissions changed event on UserManager

Open nidaren opened this issue 3 years ago • 0 comments

Is your feature request related to a problem? Please describe. Nope.

Describe the solution you'd like

Adding an event alongside existing:

public static ThreadSafeAction<User> OnUserLoggedIn  = new ThreadSafeAction<User>();
public static ThreadSafeAction<User> OnNewUserJoined = new ThreadSafeAction<User>();
public static ThreadSafeAction<User> OnUserLoggedOut = new ThreadSafeAction<User>();
public static ThreadSafeAction<User> OnUserInit      = new ThreadSafeAction<User>();`

that would either trigger when Admin is added and removed.

public static ThreadSafeAction<User> OnAdminStatusChanged  = new ThreadSafeAction<User>();

Describe alternatives you've considered

None for this one.

Additional context

It would allow modders to trigger their actions when user status has been changed, without the need to listen for ChatSent and filtering commands from it or using reflection.

nidaren avatar Apr 12 '22 20:04 nidaren