Spiritual successor and extension to #17798, an almost entire rebuild of the SQL ban system backend and interface.
Bantypes are removed per #8584 and #6174. All bans are now 'role bans', server bans are when a ban's role is server. Admin bans are a column, meaning it's possible to ban admins from jobs.
Bans now have only an expiry datetime, duration is calculated from this when queried.
unbanned column is removed as it's superfluous, checking unban status is now done through checking unban_datetime. unban_round_id column added. Each ip and computerid columns rearranged so ip is always first, like in other tables. Bans now permit a null ckey, ip and computerid.
Ban checking is split into two procs now is_banned_from() does a check if a ckey is banned from one or more roles and returns true or false. This effectively replaces jobban_isbanned() used in simple if() statements. If connected a client's ban cache is checked rather than querying the DB. This makes it possible for a client connected to two or more servers to ignore any bans made on one server until their ban cache is rebuilt on the others. Could be avoided with cross-server calls to update ban caches or just the removal of the ban cache but as is I've done neither since I think it's enough of an edge case to not be worth it.
The second proc is is_banned_from_with_details(), this queries the DB for a role ban on a player's ckey, ip or CID and returns the details. This replaces direct queries in IsBanned.dm and the preferences menu.
The legacy ban system is removed.
The interfaces for banning, unbanning and editing bans have been remade to require less clicking and easier simultaneous operations. The banning and jobban panel are combined. They also store player connection details when opened so a client disconnecting no longer stops a ban being placed.
New banning panel:
Key, IP and CID can all be toggled to allow excluding them from a ban.
Checking Use IP and CID from last connection lets you enter only a ckey and have the DB fill these fields in for you, if possible.
Temporary bans have a drop-menu which lets you select between seconds, minutes, hours, days, weeks, months and years so you don't need to calculate how many minutes a long ban would be. The ban is still converted into minutes on the DB however.
Checking any of the head roles will check both of the boxes for you.
The red role box indicates there is already a ban on that role for this ckey. You can apply additional role bans to stack them.
New unbanning panel:
Unbanning panel is now separate from the banning panel but otherwise functionally the same.
Ban editing panel:
Actually just a modified banning panel, all the features from it work the same here.
You can now edit almost all parameters of a ban instead of just the reason.
You can't edit severity as it's not really part of the ban.
The panels have been tested but I've not been able to get my local server to be accessible so ban functionality isn't properly confirmed. Plenty of testing will be required as I'd rather not break bans.
cl
admin: Ban interface rework. The banning and unbanning panels have received a new design which is easier to use and allows multiple role bans to be made at once.
prefix: Ban search and unbanning moved to unbanning panel, which is now a separate panel to the old banning panel.
/cl
* Allows floats on all config entries that have no valid reason to disallow them
Needed for run speed changes, but I'm allowing them on any config that has no bonafide reason to disallow them.
The criteria used was "Is there a technical reason why floats should not be allowed or is there a technical/logical reason why floats would never mean anything more compared to a integer".
For instance: The cloning timer was made to allow floats because 0.5 ds increments are valid at our current fps and more would be valid at other fpses. Yes, from a practical standpoint nobody would ever want to have cloning be valid for 30 minutes and 50 milliseconds after death, but from a technical standpoint there is no reason not to let them.
* Update general.dm
* Initial stage
* final changes?
* Tweaks
* removed bad variables
* Fixed more bad vars
* is this map merged?
* spelling fix
* spelling fix
Co-Authored-By: TheDreamweaver <austin.j.rickli@gmail.com>
* Map fix?
* now this is map merger
* Fixed summoning edge cases
* Fixed spelling mistakes, Added better handling of sphere removal, Added sphere to the cargo shuttle blacklist, Made the "mystery" more dynamic
* Added better handling of stored mob summoning
* Removed redundant code.
* Made the jukebox actually accessible
* Tweaked it so that no maps would need to be loaded on Init
* comment commit
* No src
* Fixed spelling and getting trapped in rocks
* Fixed spawned-in hotel checks
* Blacklisted hotel are from blueprints and migrated storage handling from door to area.
* Prevents observing mobs (ghosts, camera entities) from getting stored.
* Condensed an if statement
* The hotel can now be used on another mob to invite them to the hotel. All living mob types can now exit out the hotel door.
* Fixed wrong user getting prompted when hotel was used on someone else.
* Added peepholes to hotel doors that can be used via AltClick.
* For the grammar lovers.
Also improves the code for anomalies a bit
cl MrDoomBringer
tweak: Random Events now have a follow link for ghosts!
/cl
Untested, and anomalies are broken right now but that takes like 2 seconds to fix
fixes#41106 since it'll have it's own fucking location.
cl ShizCalev
add: Admins can now personalize their asay message color on servers with the feature enabled.
tweak: Moved some admin only preference verbs out of the Preferences tab and to a new admin preferences tab to help unclutter it / prevent accidental toggling of fun things.
/cl
Note that the start of the admin message will still use the default formatting just so it can be quickly recognized as an admin message and not an OOC one.
Yeah yeah I know no opening too many WIP PRs but this one's [ready] and I want to make sure any furthur techweb development doesn't keep using the old reference system which will make refactoring it harder, and this makes it easier for coders to do stuff in theory (at least for me), standardizes getting a node/design, and makes stuff actually GC properly.
* Overhaul mecha logging
Removes user access to the log, not needed and that log can get large
removes all the internal log vars and passes all logging through to a
new log file, the mecha log
* somehow this makes it compile
* add it to the config too