Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[MIRROR] Cleans up some admin-related stuff in client
Destroy()
and…
… `adminGreet()` (#2664) * Cleans up some admin-related stuff in client `Destroy()` and `adminGreet()` (#83427) ## About The Pull Request It made me really mad to see a huge list in the middle of client/Destroy for something that doesn't even run for 95% of users so I split it out into another proc so the fingerprint of the very important `Destroy()` stuff could be as minimal as possible without a big `pick()` so the server can send the "I need a man 🥺" message could be punted off to where no-one would care for it. It was already doing the async TGS operation so it doesn't matter anyways as far as proc overhead in my books. I also fixed up the code for `adminGreet()` as well because that was being really weird with not having proper booleans and running `pick()` on things with literally one value (as well as excess stringification)... it wasn't good so I just cleaned all that up too. Ideally this all means we take up a little less CPU time but the aim of this PR is to just clean it all up for modern coding standards. alphabetized lists and early returns galore. ## Why It's Good For The Game Code is better to read and less idented, and better yet it's no longer necessary to read all the softie messages in the middle of `Destroy()` ## Changelog Irrelevant * Cleans up some admin-related stuff in client `Destroy()` and `adminGreet()` --------- Co-authored-by: san7890 <[email protected]> Co-authored-by: NovaBot13 <[email protected]>
- Loading branch information