NebulaModTeam / nebula

A multiplayer mod for the game Dyson Sphere Program
GNU General Public License v3.0
835 stars 124 forks source link

Remove CommonAPI dependency #612

Closed starfi5h closed 9 months ago

starfi5h commented 9 months ago

chat config

PhantomGamers commented 9 months ago

Why is CommonAPI still included as a soft dependency then? Do we leverage it at all after this PR?

starfi5h commented 9 months ago

The soft dependency is added to preserve the load order that Nebula is loaded after CommonAPI. I'm not sure if CommonAPI has code that is sensitive to load order, so maybe it can be removed?

As for usage, here are some warnings from chatwindow after disable CommonAPI

[Warning: Unity Log] The referenced script (CommonAPI.UIWindowResize) on this Behaviour is missing!
[Warning: Unity Log] The referenced script (CommonAPI.MaterialFixer) on this Behaviour is missing!
[Warning: Unity Log] The referenced script on this Behaviour (Game Object 'ChatV2') is missing!

So after this PR, Nebula can run without CommonAPI but with less features. Whether to include CommonAPI in thunderstore dependencies can be discussed.