kick: cleanup

- simplify and reduce calls of core.get_player_privs()
- update help text to standard syntax
- streamline duplicate code
- remove unnecessary param count checks
- remove explicit nil check where not needed
- don't call get_owner if is admin (until needed)
This commit is contained in:
Luke aka SwissalpS
2024-09-15 06:09:33 +02:00
parent 6efb00ec69
commit c68ccd6f44
3 changed files with 19 additions and 24 deletions

View File

@ -70,7 +70,7 @@ You are the owner of multiple factions, you have to choose one of them: @1.=
You don't own any factions, you can't use this command.=
You don't own any factions.=
You cannot kick the owner of a faction, use '/factions chown <player> [faction]' to change the ownership.=
You cannot kick the owner of a faction, use '/factions chown <player> <password> [<faction>]' to change the ownership.=
You cannot leave your own faction, change owner or disband it.=
No factions found.=