more edge case

This commit is contained in:
JohnCorby 2021-12-13 22:16:32 -08:00
parent 3c0cdcb076
commit 8210793f56
2 changed files with 11 additions and 3 deletions

View File

@ -55,7 +55,6 @@ namespace QSB.OrbSync.Events
{
orbSync.NetIdentity.SetAuthority(message.FromId);
}
orbSync.enabled = true;
if (!isLocal && !orbSync.Orb._isBeingDragged)
{
@ -75,8 +74,6 @@ namespace QSB.OrbSync.Events
orbSync.Orb._interactibleCollider.enabled = true;
}
}
DebugLog.DebugWrite($"orb {message.ObjectId} drag {message.State}");
}
}
}

View File

@ -5,6 +5,8 @@ using QSB.ClientServerStateSync;
using QSB.Events;
using QSB.Messaging;
using QSB.MeteorSync.WorldObjects;
using QSB.OrbSync;
using QSB.OrbSync.TransformSync;
using QSB.QuantumSync;
using QSB.Tools.TranslatorTool.TranslationSync;
using QSB.Tools.TranslatorTool.TranslationSync.WorldObjects;
@ -75,6 +77,15 @@ namespace QSB.Player.Events
{
QSBEventManager.FireEvent(EventNames.QSBPlayerInformation);
}
// SPECIAL CASE: whoever owns the orbs sends their drag state
foreach (var sync in NomaiOrbTransformSync.Instances)
{
if (sync && sync.HasAuthority && sync.Orb)
{
QSBEventManager.FireEvent(EventNames.QSBOrbUser, OrbManager.Orbs.IndexOf(sync.Orb), sync.Orb._isBeingDragged);
}
}
}
finally
{