PSO Remake is still in the works apparently

Dumb question here. Does garbage collection affect things with C#/Unity?. I had problems in java with programs pausing or not knowing when destructors would be called.

Yes, GC is a big pain point in Unity3D at the moment. Due to old Mono licensing problems from Xaramin, pre-MS acquisition, Unity3D was unable to utilize modern GC. They were stuck with an old non-generational GC from the Mono 2.0 days or something similar to that effect.

GC pauses aren't a huge problem in modern .NET as the GC algorithm continues to improve but Unity3D suffers from a very poor GC and so allocations per-frame HAVE to be avoided. Generally the biggest source of allocations appear to be concatenating strings in the naive way. If you don't do this then you often won't run into GC problems on Desktop. Assuming you're not doing anything crazy every single frame.

Fear not though! This is something that will be addressed soon(tm) with 5.6 or 5.7 bring net46 and 5.7 and 5.8 potentially bringing an update to the GC algorithm. Supposedly they can't do both at once. But this isn't just a guess of mine. It's part of announcements and can be seen on their Roadmap somewhere.

Here is a Unite slide about it:

upload_2016-6-1_17-8-4-png.187505


edit: Also, there is no such thing as a C# deconstructor. There is a concept of finalization but it should almost always not be used. They encourage the IDisposable pattern instead. Finalization is not dependable and shouldn't really be relied upon afaik.
 
Back
Top