This commit is contained in:
JohnCorby 2022-01-18 02:00:50 -08:00
parent 73f259c039
commit d1b9c31eca
2 changed files with 2 additions and 4 deletions

View File

@ -27,7 +27,7 @@ namespace QSB.Player
return localInstance.Player;
}
}
public static uint LocalPlayerId => LocalPlayer.PlayerId;
public static uint LocalPlayerId => LocalPlayer?.PlayerId ?? uint.MaxValue;
/// <summary>
/// called right after player is added

View File

@ -113,11 +113,9 @@ namespace QSB
// WorldObject managers
QSBWorldSync.Managers = typeof(WorldObjectManager).GetDerivedTypes()
.Select(x => (WorldObjectManager)this.gameObject.AddComponent(x))
.Select(x => (WorldObjectManager)gameObject.AddComponent(x))
.ToArray();
Helper.HarmonyHelper.EmptyMethod<ModCommandListener>("Update");
QSBPatchManager.OnPatchType += OnPatchType;
QSBPatchManager.OnUnpatchType += OnUnpatchType;
}