The Performance Updates: Difference between revisions

From Resonite Wiki
Remove bad statements
Rewrite a bit
Line 1: Line 1:
(This article is written in past-tense even though the performance updates have not been released yet)
The performance updates are a series of updates made to the game in response to [https://github.com/Yellow-Dog-Man/Resonite-Issues/issues/706 Issue 706].
The performance updates are a series of updates made to the game in response to [https://github.com/Yellow-Dog-Man/Resonite-Issues/issues/706 Issue 706].


== The Issue ==
== The Issue ==
The game worked differently before the closing and conclusion of the issue. The game used a single process, that was started by the initalization of the UnityPlayer.exe file. This player would have a unity scene with a script in it that would boot [[FrooxEngine]]. FrooxEngine would be updated by this script every frame, and update things in the scene directly via monobehavior scripts.
Prior to the issue being closed, the game used a single Unity process which ran [[FrooxEngine]] in a MonoBehavior (Unity component).


The issues with this system were many. These issues in the past would cause unity to crash outside of FrooxEngine's control (Often even when FrooxEngine wasn't even doing anything). This used to take FrooxEngine down with it, causing the entire game to close.
The main issue with this was that if Unity crashed it would take down FrooxEngine with it.


The game when running under Unity was using a C# runtime called "Mono", which was very slow. The idea of the update was to update the game to initally .net 8, but during the updates .net 9 came out and FrooxEngine's runtime was updated to that at the conclusion.
The game when running under Unity was using a C# runtime called "Mono", which was very slow. The performance updates would change the runtime to .NET 9.


== The Solution ==
== The Solution ==
Frooxius in response decided to create a series of updates that were separated into different parts. The main focus of the updates were to separate Unity and FrooxEngine by bringing things simulated partly by Unity fully into Resonite.
Frooxius decided to create a series of updates that were separated into different parts. The main focus of the updates were to separate Unity and FrooxEngine by bringing things simulated partly by Unity fully into FrooxEngine.


These major Steps were:
These major Steps were:
Line 16: Line 18:
* Unity Connectors -> Inter Process Communication (Last stage and final release)
* Unity Connectors -> Inter Process Communication (Last stage and final release)


These updates changed some core components of the game, and allowed FrooxEngine to work as entirely stand alone without relying on unity for audio and particles. The game engines were then separated into two separate EXE files or Processes. Resonite now boots directly, and boots it's render engine as a separate EXE. FrooxEngine then sends data into a shared memory section in the ram, which the render engine accesses.
These updates changed core components of the game, and allowed FrooxEngine to work as entirely standalone without relying on Unity for audio or particles. The game engines were then separated into two separate processes. Resonite now boots directly, and boots it's render engine as a separate EXE. FrooxEngine then sends data into a shared memory file, which the render engine accesses.


This change allowed FrooxEngine (A now separate exe) to have it's code compiled into a new runtime (same code different executor). This marked a major turning point in the game, and also allowed for more freedom when making systems or new content.
This change allowed FrooxEngine (A now separate exe) to have it's code compiled into a new runtime (same code different executor). This marked a major turning point in the game, and also allowed for more freedom when making systems or new content.

Revision as of 11:36, 11 June 2025

(This article is written in past-tense even though the performance updates have not been released yet)

The performance updates are a series of updates made to the game in response to Issue 706.

The Issue

Prior to the issue being closed, the game used a single Unity process which ran FrooxEngine in a MonoBehavior (Unity component).

The main issue with this was that if Unity crashed it would take down FrooxEngine with it.

The game when running under Unity was using a C# runtime called "Mono", which was very slow. The performance updates would change the runtime to .NET 9.

The Solution

Frooxius decided to create a series of updates that were separated into different parts. The main focus of the updates were to separate Unity and FrooxEngine by bringing things simulated partly by Unity fully into FrooxEngine.

These major Steps were:

  • PhotonDust (Particles update)
  • Awwdio (Audio update)
  • Unity Connectors -> Inter Process Communication (Last stage and final release)

These updates changed core components of the game, and allowed FrooxEngine to work as entirely standalone without relying on Unity for audio or particles. The game engines were then separated into two separate processes. Resonite now boots directly, and boots it's render engine as a separate EXE. FrooxEngine then sends data into a shared memory file, which the render engine accesses.

This change allowed FrooxEngine (A now separate exe) to have it's code compiled into a new runtime (same code different executor). This marked a major turning point in the game, and also allowed for more freedom when making systems or new content.

Resources