Commit Graph

88 Commits

Author SHA1 Message Date
DrSmugleaf
ca0fb3c6a2 Track rule reading in database, don't show popup locally (#7278) 2022-03-26 20:16:57 +01:00
Vera Aguilera Puerto
eb54f4b224 Adds Network Resource Uploading for admins. (#6904)
Co-authored-by: Pieter-Jan Briers <pieterjan.briers@gmail.com>
Co-authored-by: Pieter-Jan Briers <pieterjan.briers+git@gmail.com>
2022-03-26 12:46:37 +01:00
Julian Giebel
414d226ec5 Server names and admin log full-text search (#6327)
Co-authored-by: Julian Giebel <j.giebel@netrocks.info>
Co-authored-by: Pieter-Jan Briers <pieterjan.briers+git@gmail.com>
2022-03-13 18:36:48 +01:00
ShadowCommander
4825142210 Role bans (#6703) 2022-02-21 23:11:39 +01:00
Pieter-Jan Briers
5091c6aa9d Revert "Revert "Log ban hits in DB. ( (#6361) 2022-02-02 22:57:11 +01:00
Pieter-Jan Briers
764010fea0 Revert "Log ban hits in DB. (#6337)" (#6357)
This reverts commit b75f005bb4.
2022-01-28 19:33:09 +01:00
Pieter-Jan Briers
b75f005bb4 Log ban hits in DB. (#6337) 2022-01-28 19:10:44 +01:00
Moony
ca984036d6 Upstream species (#6066)
* Step 1 of porting; grabbed most of the files via patches.

* Add species field to the DB

* Appearance patches for slimes.

* Fix the db test.

* Add slime's biocompat.

* slimby

* Fixes, allow specifying if a species is playable or not.

* Update Content.Client/Preferences/UI/HumanoidProfileEditor.xaml.cs

Co-authored-by: Javier Guardia Fernández <DrSmugleaf@users.noreply.github.com>

* Update Content.Client/Preferences/UI/HumanoidProfileEditor.xaml.cs

Co-authored-by: Javier Guardia Fernández <DrSmugleaf@users.noreply.github.com>

* Update Content.Client/Preferences/UI/HumanoidProfileEditor.xaml.cs

Co-authored-by: Javier Guardia Fernández <DrSmugleaf@users.noreply.github.com>

* Address reviews.

* Address reviews.

* make an if-case.

* Fix a goof where species wouldn't get shown in the editor correctly (it'd always default to human)

Co-authored-by: Javier Guardia Fernández <DrSmugleaf@users.noreply.github.com>
2022-01-08 19:53:14 -06:00
mirrorcult
af785f873f Optional server whitelists (#5979) 2022-01-05 00:37:06 +11:00
DrSmugleaf
1f8152cb02 Cache the last 3 rounds of admin logs in memory
Reduces send logs time from 2/10/45 seconds to 2 milliseconds
Not thread safe
Removes LogRecord
2021-12-25 02:07:12 +01:00
DrSmugleaf
47733b0b22 Fix adding duplicate player entries upon relogging
Fixes https://github.com/space-wizards/space-station-14/issues/5882
2021-12-23 22:13:15 +01:00
DrSmugleaf
dc9ae49126 Fix error when getting players from a log
Also potentially fix FilterTests.Date
2021-11-24 22:07:54 +01:00
DrSmugleaf
c3fe5909ad THE RETURN OF THE KING
This reverts commit c18d07538a.
2021-11-22 19:08:27 +01:00
DrSmugleaf
c18d07538a Revert "Admin logs (#5419)"
This reverts commit 319aec109d.
2021-11-22 18:55:17 +01:00
Javier Guardia Fernández
319aec109d Admin logs (#5419)
* Add admin logging, models, migrations

* Add logging damage changes

* Add Log admin flag, LogFilter, Logs admin menu tab, message
Refactor admin logging API

* Change admin log get method names

* Fix the name again

* Minute amount of reorganization

* Reset Postgres db snapshot

* Reset Sqlite db snapshot

* Make AdminLog have a composite primary key of round, id

* Minute cleanup

* Change admin system to do a type check instead of index check

* Make admin logs use C# 10 interpolated string handlers

* Implement UI on its own window
Custom controls
Searching
Add admin log converters

* Implement limits into the query

* Change logs to be put into an OutputPanel instead for text wrapping

* Add log <-> player m2m relationship back

* UI improvements, make text wrap, add separators

* Remove entity prefix from damaged log

* Add explicit m2m model, fix any players filter

* Add debug command to test bulk adding logs

* Admin logs now just kinda go

* Add histogram for database update time

* Make admin log system update run every 5 seconds

* Add a cap to the log queue and a metric for how many times it has been reached

* Add metric for logs sent in a round

* Make cvars out of admin logs queue send delay and cap

* Merge fixes

* Reset some changes

* Add test for adding and getting a single log

* Add tests for bulk adding logs

* Add test for querying logs

* Add CallerArgumentExpression to LogStringHandler methods and test

* Improve UI, fix SQLite, add searching by round

* Add entities to admin logs

* Move distinct after orderby

* Add migrations

* ef core eat my ass

* Add cvar for client logs batch size

* Sort logs from newest to oldest by default

* Merge fixes

* Reorganize tests and add one for date ordering

* Add note to log types to not change their numeric values

* Add impacts to logs, better UI filtering

* Make log add callable from shared for convenience

* Get current round id directly from game ticker

* Revert namespace change for DamageableSystem
2021-11-22 18:49:26 +01:00
Javier Guardia Fernández
720e750e86 Merge player database models (#5267) 2021-11-11 17:54:02 +01:00
Javier Guardia Fernández
af579b15cc Update to .NET 6 and C# 10 (#5233)
Co-authored-by: Pieter-Jan Briers <pieterjan.briers+git@gmail.com>
2021-11-09 15:05:07 +01:00
Pieter-Jan Briers
7f3d064ec4 Fix character slot deletion on postgres.
Fixes #4860
2021-10-13 21:11:20 +02:00
Visne
b7dc3c81ae Remove redundant #nullable enable (#4275) 2021-07-16 17:37:09 -07:00
DrSmugleaf
ff1a2d97ea Re-organize all projects (#4166) 2021-06-09 22:19:39 +02:00
ShadowCommander
7a842f7c22 Fix tests (#3707)
* First pass

* Fix access and rename banananium to bananium

* Fix captialization of CookTimeInfoLabel

* Fix InteractUsing calls

* Remove unused [Dependency]

* Replace obsolete references to Anchored with BodyType

* Assign default value to shoving someone in disposals

* Fix naming

* Replace Initialize TryGetComponents with EnsureComponent

* Rework AnchorableComponent

* Fix singularity component

* Replace obsolete usages of Angle.South

* Fix efcore warning

* Fix container tests

* Fix DebugPressurePump invalid PressurePump yaml

* Fix getting pathfinding region of grid 0

* Fix atmos plaque missing layer and add info message when it happens

* Fix AiSteeringSystem steering in an invalid grid in entity test

* Make content able to choose which log level leads to test failures

* Revert container test fix for Acruid

* Fix sprite, pipe and saving errors
Make EntityTest print all errors instead of stopping on the first

* Reorder singularity visualizer

* Disable pvs for container occlusion adn simple predict reconcile, they use entities other than map ones

Co-authored-by: Metal Gear Sloth <metalgearsloth@gmail.com>
Co-authored-by: DrSmugleaf <DrSmugleaf@users.noreply.github.com>
Co-authored-by: metalgearsloth <comedian_vs_clown@hotmail.com>
2021-03-31 21:41:23 +02:00
Pieter-Jan Briers
0ac4c0e85c SKREEEEEE (#3706)
* Import bird sprites and define basic mob.

* SKREEEEEEEEE

* Move hair styles to new sprite accessory prototypes.

Basic stuff, no multi-species stuff yet.

* Vox hair styles and clothes

* Make HumanoidCharacterProfile.Default() a static default to fix tests.

Usages that wanted the previous random behavior now call Random().

* Remove names from hair style prototypes.

(They're in localization files)

* Update Content.Shared/Actions/ActionType.cs

(sk)reeee github

Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
2021-03-28 17:26:32 +11:00
Pieter-Jan Briers
a321b4302e Use HWIDs for bans. 2021-03-22 01:32:09 +01:00
Remie Richards
85916b87b4 Fluent Localisation Fixes (#3344)
Co-authored-by: Pieter-Jan Briers <pieterjan.briers+git@gmail.com>
2021-02-22 01:07:46 +01:00
Leo
a3d0e3f6a7 OOC sent by an admin will have a different color (#3117)
* Admin OOC is sent with a different color than regular OOC

- Also adds the OOC color to the database

* Command to set the color

* Ooc -> OOC

* Change default color to Red (`#ff0000`)

* Outdated namespace
2021-02-14 15:59:56 +01:00
DrSmugleaf
f4978d1b9e Add pardon command and tests (#3190)
* Add pardon command

* Make pardoning check for an existing ban and unban first

* Add pardon test and documentation
2021-02-13 17:51:54 +01:00
DrSmugleaf
9f5fca2334 Add banlist command (#3163)
* Add banlist command

* Fix up args
2021-02-12 13:04:32 +01:00
Swept
81730e2612 Backpack preferences. (#2864)
Co-authored-by: Pieter-Jan Briers <pieterjan.briers+git@gmail.com>
2021-01-03 16:22:14 +01:00
20kdc
6b5cded8c2 Clothing and pronoun fields (#2689)
* Clothing & Gender fields: Add to database [MODIFIED TO NOT DEPEND ON SAPHIRE-DB-REFACTOR]

Sorry about this, Saphire.

* Clothing & Gender fields: Add UI [FALLBACK II]

* Clothing & Gender fields: Actually apply gender

* Clothing & Gender fields: Import innerclothingskirt field from my previous attempt

Couldn't import actual prototypes because of a change to IDs

* Clothing & Gender fields: Add innerclothingskirt field to everything

* Clothing & Gender fields: Jumpskirts now work

* Clothing & Gender fields: Gender field will follow sex field if it's not different (UX improvement) [FALLBACK II]

* Clothing & Gender fields: Gender -> Pronouns to reduce confusion. Also, fix profile summary. Properly. [FALLBACK II]

* Clothing & Pronoun fields: Refactor so that profile equipment adjustments are performed in StartingGearPrototype.
2020-12-24 14:42:40 +01:00
DrSmugleaf
06b1939a60 Update usages of ! is with is not (#2584)
* Update usages of ! is with is not

* Content.IntegrationTests commit

* Content.Server commit

* Content.Shared commit

Co-authored-by: Metal Gear Sloth <metalgearsloth@gmail.com>
2020-11-27 00:33:31 +11:00
Pieter-Jan Briers
4b5ab508ed Fix postgres problems with admins. 2020-11-13 03:23:13 +01:00
Pieter-Jan Briers
e39ddd4802 Permissions panel. 2020-11-10 16:50:28 +01:00
Pieter-Jan Briers
6980ff84b0 Fix include calls for the admin DB stuff. 2020-11-02 00:23:34 +01:00
Pieter-Jan Briers
0e419ad321 Fix include calls for the admin DB stuff. 2020-11-02 00:22:53 +01:00
Pieter-Jan Briers
ad58a056d7 ConGroups are gone. Long live admin flags in content. 2020-10-30 16:06:48 +01:00
Pieter-Jan Briers
882ed619fd Don't allow deletion of the selected character slot. 2020-10-07 18:04:15 +02:00
Pieter-Jan Briers
390d064304 Re-organize in-memory character profile storage.
Now uses a dictionary of int -> profile instead of an array filled with nulls.
2020-10-06 15:13:16 +02:00
Pieter-Jan Briers
66c8a68891 Holy crap auth works (#2099)
* Holy crap auth works

* Fix some usages of UserID instead of UserName

* Refactor preferences.

They be non-async now. Also faster.

* Rename DbContext.

* Guest username assignment.

* Fix saving of profiles.

* Don't store data for guests.

* Fix generating invalid random colors.

* Don't allow dumb garbage for char preferences.

* Bans.

* Lol forgot to fill out the command description.

* Connection log.

* Rename all the tables and columns to be snake_case.

* Re-do migrations.

* Fixing tests and warnings.

* Update submodule
2020-09-29 14:26:00 +02:00