Chalwk / HALO-SCRIPT-PROJECTS

:white_check_mark: Halo PC|CE - Add-ons for Phasor V2+ and SAPP :new_zealand:
Other
32 stars 13 forks source link

Admin Managemente & Vote Kick Updates #147

Closed edgardanielgd closed 1 year ago

edgardanielgd commented 1 year ago

Admin Management Changes

Cache for password-admins:

As default SAPP's admin management system does, logged-in admins have their level preserved after rejoining a server as well as when a new match start, this cache is based on the socket (IP:PORT) a player uses when logging in as an admin. Within this update we use the same idea, password admins will remain cached by the server until server restarts or the admin logs out.

Username based management for password-admins:

Usually password based admins aren't present on the server to add their admin rights, now we can add admins knowing only their desired username (This includes adding, deleting, changing password and changing level)

Bug fix:

Admin names shown in password-based admin list were null due to using a different data structure than the one used for IP and Hash based admins

Scripts generalization

Since a representative number of existing scripts use SAPP's default admin management system, and mostly its built-in $lvl player variable, we extend this custom management system by creating a custom variable $admin_level that performs the same function by storing the current player level for external use.

Vote Kick Changes

Some announcements and help commands have been added for all players usage