Skip to content

Commit

Permalink
RegisterNotRequiredForAllPlayers: check NetworkBehaviour too
Browse files Browse the repository at this point in the history
  • Loading branch information
JohnCorby committed Aug 9, 2023
1 parent 2b2eddd commit 42a0332
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion QSB/QSBCore.cs
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,9 @@ public static void RegisterNotRequiredForAllPlayers(IModBehaviour addon)

foreach (var type in addonAssembly.GetTypes())
{
if (typeof(WorldObjectManager).IsAssignableFrom(type) || typeof(IWorldObject).IsAssignableFrom(type))
if (typeof(WorldObjectManager).IsAssignableFrom(type) ||
typeof(IWorldObject).IsAssignableFrom(type) ||
typeof(NetworkBehaviour).IsAssignableFrom(type))
{
DebugLog.ToConsole($"Addon \"{uniqueName}\" cannot be cosmetic, as it creates networking objects.", MessageType.Error);
return;
Expand Down

0 comments on commit 42a0332

Please sign in to comment.