572fd2e694
Kill prototypeid serializers ( #6969 )
...
Co-authored-by: deltanedas <@deltanedas:goida.zip>
2026-08-22 16:33:17 +10:00
DrSmugleaf and GitHub
bcfe7ce3ce
Fix a few partial prototype bugs and add more tests for component inheritance ( #7030 )
2026-08-22 14:55:51 +10:00
DrSmugleaf and GitHub
a589f1473b
Add partial prototypes, for defining and modifying prototype data with the same ID in different files ( #6923 )
2026-08-20 15:39:25 -07:00
metalgearsloth and GitHub
d97a89b9f2
Add polygon occluders ( #6831 )
2026-08-07 17:18:52 +10:00
DrSmugleaf and GitHub
22d01166ff
Rewrite ReflectionManager, make SerializationManager use it ( #6877 )
2026-08-07 16:49:41 +10:00
metalgearsloth and GitHub
5e2557b947
Intern prototype components ( #6897 )
2026-08-07 00:43:54 +10:00
metalgearsloth and GitHub
026ec6b565
Pre-allocate serializer sizes ( #6927 )
2026-08-06 20:48:55 +10:00
DrSmugleaf and GitHub
435247539e
Make ComponentRegistrySerializer.Read 3.7 times faster ( #6913 )
2026-08-05 18:04:27 +10:00
DrSmugleaf and GitHub
152130bbac
Replace some usages of object reads with generic type reads ( #6914 )
2026-08-05 17:39:50 +10:00
DrSmugleaf and GitHub
762e9882e0
Add and use CopyNoType to MappingDataNode, don't copy in ComponentRegistrySerializer.Read ( #6912 )
2026-08-05 13:24:28 +10:00
DrSmugleaf and GitHub
087a7cf2d8
Make SerializationManager.TryGetTypeNodeSerializer 65 times faster ( #6915 )
2026-08-05 12:46:29 +10:00
metalgearsloth and GitHub
bc55ae00d6
Box2 + Box2Rotated performance and fixes ( #6668 )
2026-08-01 15:30:41 +10:00
metalgearsloth and GitHub
45f3caaac4
Fastpath EntityManager.IsDefault ( #6735 )
...
* Slim it down
Had the spawn mess included.
* fixes
* build fix
2026-07-24 01:07:57 +10:00
9cd8401cfb
Serializer improvement and cleanup ( #6674 )
...
Co-authored-by: deltanedas <@deltanedas:goida.zip>
Co-authored-by: metalgearsloth <comedian_vs_clown@hotmail.com >
2026-07-24 00:57:13 +10:00
b46fbefdfd
Color.cs Cleanup ( #6772 )
...
Co-authored-by: ArtisticRoomba <145879011+ArtisticRoomba@users.noreply.github.com >
2026-07-16 08:16:21 -07:00
metalgearsloth and GitHub
dcadd34389
Serv5 fixes ( #6761 )
2026-07-09 00:08:10 +10:00
34ce2ba534
serv5 ( #6496 )
...
* Add source generator for DataDefinition validation
* Add source generator for reading
* Add source generator for writing
* Include prototypes and other meansdatadefinition types
* Target ISerializationGenerated in data definitions
* Murder
* Use array, struct, enum methods
* Source generate get field definitions
* serv5
* Fix and pray
* Fix release compile
* Tayrtahn review
* a
* Generator bugfix
---------
Co-authored-by: metalgearsloth <comedian_vs_clown@hotmail.com >
2026-07-08 22:18:35 +10:00
Leon Friedrich and GitHub
7b25f1e256
Fix DataRecord serialization ( #6619 )
2026-06-27 17:59:35 +10:00
metalgearsloth and GitHub
8f6ebad5b9
Reduce game memory usage a crumb ( #30 )
2026-06-19 21:55:44 +10:00
deltanedas and deltanedas
dc2cbd952f
CompName gaming
2026-06-17 19:54:42 +01:00
83c2a1be11
[Dependency] source generator part 2 ( #6550 )
...
* [Dependency] source generator
No more reflection, no more codegen at runtime
Also various changes to Roslyn helpers to make this easier to write.
Requires all types with dependencies to be partial and not have readonly dependency fields. An analyzer enforces this at warning level, the previous injection strategies have remained in the code *for now* as a fallback.
No fallback is available for [field: Dependency] properties, due to a Roslyn bug.
Code Fixes exist. We love Roslyn
* Apply dependencies generator changes to all code
* Release notes
* Preprocessor got hands
* Handle nullable dependencies
These are bad but gotta deal with it.
* Apply suggestions from code review
Co-authored-by: Moony <moony@hellomouse.net >
* Fine, let's not use collection expressions
---------
Co-authored-by: Moony <moony@hellomouse.net >
2026-05-08 12:38:33 +02:00
PJB3005
65b8d0cce2
Add network serialization float NaN sanitization
...
Apparently cheat clients have figured out that none of SS14's code does validation against NaN inputs. Uh oh.
IRobustSerializer can now be configured to remove NaN values when reading. This is intended to be set on the server to completely block the issue.
Added "Unsafe" float types that can be used to bypass the new configurable behavior, in case somebody *really* needs NaNs.
An alternative option was to make a "SafeFloat" type, and only apply the sanitization to that. The problem is that would require updating hundreds if not thousands of messages in SS14, and probably significantly confuse contributors on "when use what." Blocking NaNs by default is likely to cause little issues while ensuring the entire exploit is guaranteed impossible.
2026-01-25 03:45:50 +01:00
PJB3005
e308b89fe6
Log string map size
2025-12-22 17:56:16 +01:00
PJB3005
bb81d88653
Add [NotContentImplementable] to shared interfaces
2025-12-20 16:49:35 +01:00
PJB3005
ddfa12808c
Fix some roslyn tests
2025-12-17 16:55:33 +01:00
4747e5a05a
Add and update a lot of documentation ( #6337 )
...
* Serialization docs
Co-authored-by: Moony <moonheart08@users.noreply.github.com >
* ECS docs
Co-authored-by: Moony <moonheart08@users.noreply.github.com >
* scattered docs
Co-authored-by: Moony <moonheart08@users.noreply.github.com >
* Fixes
---------
Co-authored-by: Moony <moonheart08@users.noreply.github.com >
Co-authored-by: PJB3005 <pieterjan.briers+git@gmail.com >
2025-12-15 20:26:17 +01:00
Pieter-Jan Briers and GitHub
d161c3b3b8
Add FormattedString type ( #6339 )
...
This is basically a lightweight marker type saying "this string contains markup". Intended to avoid injection accidents if people don't realize they should escape stuff.
2025-12-15 19:36:16 +01:00
PJB3005
fe35a24e88
Basic prototype string interning
...
From my extremely rough and unscientific tests, this saves like 15 MB of client memory on the main menu. Probably also just improves load speed on startup too.
It's per file to keep the implementation simple.
2025-12-09 12:31:50 +01:00
PJB3005
6bbeaeeba6
Fix NetBitArraySerializer compatibility.
...
Apparently NetSerializer treats IDynamicTypeSerializer and IStaticTypeSerializer differently for sealed types??
2025-12-02 00:51:04 +01:00
PJB3005
b267cd6fb4
Actually add NetBitArraySerializer to RobustSerializer
...
oops
#6301
2025-11-15 18:46:01 +01:00
PJB3005
83ad6042a7
Fix BitArray serialization for .NET 10
...
Fixes #6301
2025-11-15 18:41:43 +01:00
8b7fbfa646
Add two new custom yaml serializers ( #6253 )
...
* Add two new custom yaml serializers
* make ComponentNameSerializer ignore ignored components
---------
Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com >
2025-10-27 23:05:46 +11:00
Leon Friedrich and GitHub
912b6da20a
Fix serialization of data-records with get-only properties ( #6204 )
...
* Fix serialization of data-records with get-only properties
* even less nesting
* asserts
2025-09-17 19:11:12 +02:00
Pieter-Jan Briers and GitHub
f02cd0083a
Make SpriteSpecifier.Texture fail validation if it contains ".rsi" ( #6155 )
...
No pointing to PNGs inside RSIs.
2025-09-02 22:05:13 +02:00
John and GitHub
fb0ec52f8c
Fix TimeSpan overflow on Read ( #6170 )
...
A lot of areas use TimeSpan.MaxValue but when saved and read the current time is added which results in an overflow.
A check is now performed to prevent this.
2025-08-30 00:59:39 +02:00
PGray and GitHub
23c90c0c45
Serialization: Make null literal check culture-invariant ( #6136 )
...
Use StringComparison.OrdinalIgnoreCase instead of ToLower() to avoid culture-sensitive casing issues (e.g., Turkish-i) when detecting YAML null literals.
2025-08-12 13:28:30 +02:00
Pieter-Jan Briers and GitHub
dcbe0505dc
Revert "Add WeakEntityReference ( #5577 )" ( #6112 )
...
This reverts commit c3489d4ded .
2025-07-29 18:22:17 +02:00
c3489d4ded
Add WeakEntityReference ( #5577 )
...
* Add WeakEntityReference
* Use NetEntity
* release notes
* A
* Fix merge conflicts
* comments
* A
* Add network serialization test
* Add ToPrettyString support for WeakEntityReference?
* inheritdoc
* Add GetWeakReference methods
* Not-nullable too
* Make EntitySystem proxy method signatures match EntityManager
* Add TryGetEntity
* interface
* fix test
* De-ref GetWeakReference methods
---------
Co-authored-by: Tayrtahn <tayrtahn@gmail.com >
2025-07-29 11:12:49 -04:00
Pieter-Jan Briers and GitHub
cdd3afaa4c
Remove redundant custom math types ( #6078 )
...
Vector3, Vector4, Matrix4, and Quaternion are now gone. Use System.Numerics instead.
This commit is just replacing usages, cleaning up using declarations, and moving over the (couple) helpers that are actually important.
2025-07-23 01:15:27 +02:00
Nemanja and GitHub
ceeb002692
Mark ValidatePrototypeIdAttribute as obsolete ( #6062 )
2025-07-12 15:20:08 +02:00
4851e913b0
More TimespanSerializer improvements ( #5910 )
...
* improved public TryTimeSpan
* don't want any locale shenanigans or misconceptions with the input
* missed a test line
* also support capitalized time unit indicators
* Doesn't need to be nullable.
---------
Co-authored-by: PJB3005 <pieterjan.briers+git@gmail.com >
2025-07-11 20:37:39 +02:00
Tayrtahn and GitHub
a45b72a1c5
IRobustCloneable and generator support ( #5692 )
...
* Add IRobustCloneable and check for it in compnet generator.
* Redo compnetgenerator support; add test
* Disconnect client at end of test
* Actually test for client entities
* Cleanup
* Cleanup 2
2025-06-27 20:37:43 +02:00
c73b54862e
Add analyzers to detect some prototype misuse ( #6048 )
...
* Add analyzers to detect some prototype misuse
Detects people marking prototype as NetSerializable.
Detects people creating new prototype instances themselves.
* Update Robust.Analyzers/PrototypeNetSerializableAnalyzer.cs
Co-authored-by: Tayrtahn <tayrtahn@gmail.com >
---------
Co-authored-by: Tayrtahn <tayrtahn@gmail.com >
2025-06-26 22:24:23 +02:00
PJB3005
c152fb8953
Fix culture-based parsing in TimespanSerializer
2025-06-17 16:03:20 +02:00
Tayrtahn and GitHub
fa6bd8f7ba
Cleanup TypeSerializer Logger warnings ( #5966 )
2025-05-24 20:23:28 +02:00
15d5b9aa02
Move parts of SpriteComponent to SpriteSystem ( #5602 )
...
* Partial sprite component ECS
* release notes
* tests
* Why
* SetSnapCardinals
* NoRotation
* DirectionOverride
* This is why I love distinct overrides that take in object
* LayerSetData
* ISerializationHooks continue to haunt me
* Relocate SetShader
* LayerSetSprite
* LayerSetTexture
* yipeeeee
* LayerSetRsi
* Remove GetFallbackState
* LayerSet Scale,Rotation,Color,Visible
* Fix LayerSetRsi
* LayerSetOffset
* LayerSetDirOffset
* Add overrides that take in a Layer
* LayerSetAnimationTime
* LayerSetRenderingStrategy
* Reduce Resolves, Add Layer.Index
* Access
* Try fix NREs
* Asserts
* LayerGetState
* Cleanup
* Merge helper partial classes
* partial rendering
* GetLayerDirectionCount
* Cache local bounds
* RenderLayer
* RefreshCachedState
* RoundToCardinalAngle
* Fix the pr
* Fix debug assert
---------
Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com >
Co-authored-by: metalgearsloth <comedian_vs_clown@hotmail.com >
2025-05-10 21:56:53 +10:00
Leon Friedrich and GitHub
d24854d94f
Improve yaml validation errors for ignored prototypes ( #5886 )
...
* Improve yaml validation errors for ignored prototypes
* release notes
* Comments
2025-05-10 21:37:42 +10:00
eb5ed12270
Serialize TimeSpan from text ( #5865 )
...
* timespanserializer cleanup
* string reading
* high speed, low drag
* unit tests
* Update Robust.Shared/Serialization/TypeSerializers/Implementations/TimespanSerializer.cs
---------
Co-authored-by: Pieter-Jan Briers <pieterjan.briers@gmail.com >
2025-05-05 00:57:01 +02:00
dffdff2423 and GitHub
8905a3fe14
Add documentation to the serializer interfaces and remove ITypeReaderWriter ( #5897 )
...
* Add documentation to the serializer interfaces
* Remove ITypeReaderWriter and fix the docs
* Fix spelling errors and incorrect docstrings
2025-05-04 04:03:17 +02:00
Leon Friedrich and GitHub
2f8f4f2f7a
Make MappingDataNode use string keys ( #5783 )
...
* string keys
* obsoletions
* Fix ValueTupleSerializer
* Release notes
* fix release note conflict
* cleanup
* Fix yaml validator & tests
* cleanup release notes
* a
* enumerator allocations
* Also sequence enumerator alloc
2025-04-18 19:01:34 +10:00