Update 26.02.25

Another round of optimizations and fixes, a few new features and Sandbox progress.

Editor Splash Screenby devultj

sbox-dev_Eqcq1EOeav.png 307.6 KB
The editor loading splash got a new modern look, the key change is removing all the noise and showing you only what you need instead.

You can also override the image with a splash_screen.png file in your project folder.

Editor Welcome Guideby Carson

20_09-10-YellowWaterbuffalo.mp4 2.27 MB
Added a simple onboarding process for first-time users who want to know their way around the editor. This guide can be opened again at any time via the Help menu.

Time.NowDoubleby conna

A big complaint in gmod was CurTime() losing precision after 9 hours of server uptime due to it being a single floating point. We have the same problem in s&box with Time.Now being a single float, as the server time increases stuff like gameplay, movement, interpolation and more begin to breakdown from the inaccuracy.
Figure_1.png 53.45 KB
We've exposed Time.NowDouble, this won't noticeably lose precision until at least 200 days We've moved all internal systems like interpolation to it now.

We are considering making Time.Now a double by default but this would be a breaking change.

Sandbox: Action Hintsby devultj

hints.png 382.54 KB
Sandbox tools have action hints now

Sandbox: Remove All Constraintsby devultj

0ad016776150.mp4 3.88 MB
And you are now able to remove constraints on all constraint tools by hitting reload. 

Sandbox: Dupe Spawningby devultj

When spawning in dupes, we noticed that none of it was replicated properly to other clients. This was because we batched everything -- this makes all references and Compnent methods run in order, so stuff like constraints attach properly. We were spawning them over the network inside the batch, which meant everything was empty.

We've made it so batching also batches network spawns. You can use this with Scene.BatchGroup().

And we've added a nice progress bar when spawning dupes.
sbox-dev_SN0vjYrDeK.mp4 9.73 MB

Sandbox: Weld Previewby Lorenz

20_12-32-DecentGrayreefshark.mp4 14.46 MB
The Weld Preview now shows all connected objects.

Sandbox: Physgun Tintby Layla

551533205-ab27a3c8-901c-4785-9536-6ac1b4c808da.mp4 7.8 MB
The physgun tints orange when used in pull mode.

Vertex Painting Improvementsby bakscratch

a.mp4 19.79 MB
We've added some major improvements to the vertex painting tool this week.
  • Only trace to selected surfaces
  • Can paint backfaces
  • Added selecton modes / hardness falloff
  • Layers are named, and we will only show layers that exist
  • Overhauled gizmos

Rotation Gizmo: Trackball + View-space handle

546420795-c530b2a6-c1aa-4454-a2ea-add9e3a66e4a.webm 1.81 MB
Open-source contributor DrakeFruit revamped the rotation gizmo, there is now a trackball and view-space rotation similar to Blender.

ToolsVisby Sam Pavlovic

mat_toolvis was broken for a while and could only be used in the editor. We've now moved it from C++ to C#, made it work in-game again as well as added it to the F2 console menu to quickly see and change modes.
image.png 32.72 KB

Party Improvementsby devultj

On theme for improving the platform experience, I've made some party system improvements this week.
  • When the party leader starts downloading a game, you'll start downloading the game too in the background. 
  • When they've finished, you'll go with them.
  • I've added some toasts to make it really obvious what's going on.
    image.png 13.37 KB

Dedicated Server Only Gamesby conna

We've made it so that you can now set the Launch Mode for your game to Dedicated Server Only. When set to this mode, the game can only be hosted on a Dedicated Server and when players select your game in the menu, it will bring up a list of available servers to join.
sbox_Aa75UZO7sT.mp4 9.1 MB

Incremental Compilesby solwllms

As projects' code grows in size so do compile times, when we want an editor platform where it's quick to iterate and hotload, these large compile times are not good.
image.png 40.56 KB
We've made improvements to incremental compile performance, so small changes should now recompile noticeably faster, especially in large projects.

Previously, our processors and codegen ran on the entire codebase every time you recompiled. Now, they only run on what's actually changed. Reusing more between compiles, reducing unnecessary re-parsing, allocations, and other work.

The impact of this can be pretty huge. Big projects where the difference between min/max compiles is greatest will see the most gains. In a pretty large project, compile times dropped from >8s to ~2s in my testing - a 75% reduction.

There's still more to look at with this, but hopefully a good first step. Faster iteration means better games, I prefer those personally.

Package load optimizationsby Lorenz

Package resources were loaded and reloaded multiple times during game load, which made load times longer than necessary.
image.png 410.29 KB
We cleaned up a lot of that redundant processing.
In testing, games that rely heavily on cloud packages loaded up to 20 seconds faster.


Performance Overlaysby Sam Pavlovic

68747470733a2f2f66696c65732e6661636570756e63682e636f6d2f73616d7061766c6f7669632f31623230313162312f73626f785f5a6c376b635a726c32472e706e67-2.png 144.23 KB
Source Engine had an extensive and overwhelming stats_display command, we've filtered and added the most useful parts to the performance overlays accessible through the F1 console.

Primarily this is the total frame time and GPU frame time, this is most useful for telling when you are CPU or GPU limited.

Physics out of bounds eventby Layla

If physics objects fall forever they’ll eventually end up out of bounds in the physics engine. There’s now an event for that, so you can decide what to do. Disable them, or like Sandbox does, just delete the prop.
image.png 12.86 KB

Allocations Overlayby Lorenz

.NET’s garbage collector is really solid compared to Unity's GC, which means we generally have to worry about allocations a lot less. That said, on lower-end systems  (slow memory / small CPU-Caches) we noticed that GC can significantly affect performance.

To tackle this, we’ve updated our allocation overlay to show new metrics like stutters, total GC time, and more.
24_22-58-DarkolivegreenMule.png 356.31 KB

These allocations can come from the engine or even your own games. Let us know if you spot anything that looks like an unnecessary high allocation.

Allocation Reductionsby Lorenz

With the new overlay, we found some easy wins and shaved a few MB/s away, and we’re also seeing noticeably fewer total garbage collection runs in our Deathmatch benchmark.

This should already reduce stutters caused by GC a bit, especially on lower-end systems.

Metrics for average allocations over time are here: https://sbox.game/metrics/benchmarks