Commit Graph

5 Commits

Author SHA1 Message Date
James King
689fbbd42b Call ReflectionQueryCache.ClearTypeCache in GlobalContext.OnHotload (#4409)
* Instead of in a EditorEvent.Hotload, which only happens in the editor
* Fixes exceptions on connected clients after hotload (Facepunch/sbox-public#10246, Facepunch/sbox-public#10210)
2026-03-27 15:32:15 +01:00
Lorenz Junglas
620048d225 Don't clone or serialize static members (#4273)
Ignore static members when serializing or cloning components, makes no sense and breaks cloning with Expression Trees (that was introduced in https://github.com/Facepunch/sbox/pull/4202)

Fixes https://github.com/Facepunch/sbox-public/issues/10161
2026-03-10 14:45:24 +01:00
Lorenz Junglas
51e1bb79aa Avoid allocations when deserializing RenderOptions (#4206)
* [MakeDirty] allocates a Action delegate even if it's not used.

* Use field keyword instead of manual backing fields

* Add fast path for render object cloning, avoids expensive round trip through JsonPopulator
2026-03-06 11:30:20 +01:00
Lorenz Junglas
5ee25aa42b Fix copy of value types being boxed on the heap (#4202)
ValueTypes where unclearly put on the heap when assigning `object originalValue` during cloning.
Those types now use a fast path that remains boo and allocation free by using compiled expression trees
2026-03-05 08:24:17 +01:00
s&box team
71f266059a Open source release
This commit imports the C# engine code and game files, excluding C++ source code.

[Source-Commit: ceb3d758046e50faa6258bc3b658a30c97743268]
2025-11-24 09:05:18 +00:00