Strange desync error in TrueSync's Farseer library

Context:

We added logging to let us know when 'rollbacks' happen. After a rollback, the physics broke - but it only broke in an external build, not the one that was running the editor. :(

Any ideas on what we should be tracking down?

#RollBack#13.36 Gravity mover velocity rolled back to:-21.6 UnityEngine.DebugLogHandler:Internal_Log(LogType, String, Object) UnityEngine.DebugLogHandler:LogFormat(LogType, Object, String, Object[]) UnityEngine.Logger:LogFormat(LogType, String, Object[]) UnityEngine.Debug:LogFormat(String, Object[]) GravityMover:ApplyUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Scripts\Shared\Movement\Movers.cs:318) MovableUnit:OnSyncedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Scripts\Shared\Movement\MovableUnit.cs:436) TrueSync.TrueSyncManagedBehaviour:OnSyncedUpdate() TrueSync.TrueSyncManager:OnStepUpdate(List`1) (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:781) TrueSync.AbstractLockstep:ExecutePhysicsStep(List`1, Int32) TrueSync.RollbackLockstep:Rollback(Int32, Int32) TrueSync.RollbackLockstep:BeforeStepUpdate(Int32, Int32) TrueSync.AbstractLockstep:Update() TrueSync.TrueSyncManager:FixedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:714) (Filename: Z:/Projects/Atomech/project-sidescroller/Assets/Scripts/Shared/Movement/Movers.cs Line: 318) #RollBack#13.36 Rollback from 13.36 UnityEngine.DebugLogHandler:Internal_Log(LogType, String, Object) UnityEngine.DebugLogHandler:LogFormat(LogType, Object, String, Object[]) UnityEngine.Logger:LogFormat(LogType, String, Object[]) UnityEngine.Debug:LogFormat(String, Object[]) AdvancedInputModule:OnSyncedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\NetworkedInputTest\TrueSyncInputSources\AdvancedInputModule.cs:280) TrueSync.TrueSyncManagedBehaviour:OnSyncedUpdate() TrueSync.TrueSyncManager:OnStepUpdate(List`1) (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:797) TrueSync.AbstractLockstep:ExecutePhysicsStep(List`1, Int32) TrueSync.RollbackLockstep:Rollback(Int32, Int32) TrueSync.RollbackLockstep:BeforeStepUpdate(Int32, Int32) TrueSync.AbstractLockstep:Update() TrueSync.TrueSyncManager:FixedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:714) (Filename: Z:/Projects/Atomech/project-sidescroller/Assets/NetworkedInputTest/TrueSyncInputSources/AdvancedInputModule.cs Line: 280) IndexOutOfRangeException: Array index is out of range. at TrueSync.Physics2D.DynamicTree`1[TrueSync.Physics2D.FixtureProxy].GetFatAABB (Int32 proxyId, TrueSync.Physics2D.AABB& fatAABB) [0x00019] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Collision\DynamicTree.cs:285 at TrueSync.Physics2D.DynamicTreeBroadPhase.TestOverlap (Int32 proxyIdA, Int32 proxyIdB) [0x0000a] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Collision\DynamicTreeBroadPhase.cs:226 at TrueSync.Physics2D.ContactManager.Collide () [0x00189] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Dynamics\ContactManager.cs:374 at TrueSync.Physics2D.World.Step (FP dt) [0x000c2] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Dynamics\World.cs:1210 at TrueSync.Physics2DWorldManager.UpdateStep () [0x0000d] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\Physics2DWorldManager.cs:70 at TrueSync.AbstractLockstep.ExecutePhysicsStep (System.Collections.Generic.List`1 data, Int32 syncedDataTick) [0x00000] in <filename unknown>:0 at TrueSync.RollbackLockstep.Rollback (Int32 rollbackTick, Int32 temporaryRollbackWindow) [0x00000] in <filename unknown>:0 at TrueSync.RollbackLockstep.BeforeStepUpdate (Int32 syncedDataTick, Int32 referenceTick) [0x00000] in <filename unknown>:0 at TrueSync.AbstractLockstep.Update () [0x00000] in <filename unknown>:0 at TrueSync.TrueSyncManager.FixedUpdate () [0x0006f] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:714 (Filename: Z:/Projects/Atomech/project-sidescroller/Assets/Standard Assets/TrueSync/Physics/Farseer/Collision/DynamicTree.cs Line: 285)

Comments

  • Hi @Xelnath, this is strange, can you reproduce in a sample project this issue? Because a lot of things can trigger an error on rollback procedure, it could be some mistake in our side or some in your game logic.
  • Hi Jefferson,

    The scenario is complex. It's currently only happened once inside of the standalone binary and not happened again recently. The bigger issue is the inscrutability of the error. I will reply again here if it happens again and I am able to capture more debug data.

    -Alex
  • Trying again since that code block was horrid.


    #RollBack#13.36 Gravity mover velocity rolled back to:-21.6
    UnityEngine.DebugLogHandler:Internal_Log(LogType, String, Object)
    UnityEngine.DebugLogHandler:LogFormat(LogType, Object, String, Object[])
    UnityEngine.Logger:LogFormat(LogType, String, Object[])
    UnityEngine.Debug:LogFormat(String, Object[])
    GravityMover:ApplyUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Scripts\Shared\Movement\Movers.cs:318)
    MovableUnit:OnSyncedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Scripts\Shared\Movement\MovableUnit.cs:436)
    TrueSync.TrueSyncManagedBehaviour:OnSyncedUpdate()
    TrueSync.TrueSyncManager:OnStepUpdate(List`1) (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:781)
    TrueSync.AbstractLockstep:ExecutePhysicsStep(List`1, Int32)
    TrueSync.RollbackLockstep:Rollback(Int32, Int32)
    TrueSync.RollbackLockstep:BeforeStepUpdate(Int32, Int32)
    TrueSync.AbstractLockstep:Update()
    TrueSync.TrueSyncManager:FixedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:714)

    (Filename: Z:/Projects/Atomech/project-sidescroller/Assets/Scripts/Shared/Movement/Movers.cs Line: 318)

    #RollBack#13.36 Rollback from 13.36
    UnityEngine.DebugLogHandler:Internal_Log(LogType, String, Object)
    UnityEngine.DebugLogHandler:LogFormat(LogType, Object, String, Object[])
    UnityEngine.Logger:LogFormat(LogType, String, Object[])
    UnityEngine.Debug:LogFormat(String, Object[])
    AdvancedInputModule:OnSyncedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\NetworkedInputTest\TrueSyncInputSources\AdvancedInputModule.cs:280)
    TrueSync.TrueSyncManagedBehaviour:OnSyncedUpdate()
    TrueSync.TrueSyncManager:OnStepUpdate(List`1) (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:797)
    TrueSync.AbstractLockstep:ExecutePhysicsStep(List`1, Int32)
    TrueSync.RollbackLockstep:Rollback(Int32, Int32)
    TrueSync.RollbackLockstep:BeforeStepUpdate(Int32, Int32)
    TrueSync.AbstractLockstep:Update()
    TrueSync.TrueSyncManager:FixedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:714)

    (Filename: Z:/Projects/Atomech/project-sidescroller/Assets/NetworkedInputTest/TrueSyncInputSources/AdvancedInputModule.cs Line: 280)

    IndexOutOfRangeException: Array index is out of range.
    at TrueSync.Physics2D.DynamicTree`1[TrueSync.Physics2D.FixtureProxy].GetFatAABB (Int32 proxyId, TrueSync.Physics2D.AABB& fatAABB) [0x00019] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Collision\DynamicTree.cs:285
    at TrueSync.Physics2D.DynamicTreeBroadPhase.TestOverlap (Int32 proxyIdA, Int32 proxyIdB) [0x0000a] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Collision\DynamicTreeBroadPhase.cs:226
    at TrueSync.Physics2D.ContactManager.Collide () [0x00189] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Dynamics\ContactManager.cs:374
    at TrueSync.Physics2D.World.Step (FP dt) [0x000c2] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Dynamics\World.cs:1210
    at TrueSync.Physics2DWorldManager.UpdateStep () [0x0000d] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\Physics2DWorldManager.cs:70
    at TrueSync.AbstractLockstep.ExecutePhysicsStep (System.Collections.Generic.List`1 data, Int32 syncedDataTick) [0x00000] in :0
    at TrueSync.RollbackLockstep.Rollback (Int32 rollbackTick, Int32 temporaryRollbackWindow) [0x00000] in :0
    at TrueSync.RollbackLockstep.BeforeStepUpdate (Int32 syncedDataTick, Int32 referenceTick) [0x00000] in :0
    at TrueSync.AbstractLockstep.Update () [0x00000] in :0
    at TrueSync.TrueSyncManager.FixedUpdate () [0x0006f] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:714

    (Filename: Z:/Projects/Atomech/project-sidescroller/Assets/Standard Assets/TrueSync/Physics/Farseer/Collision/DynamicTree.cs Line: 285)
  • Trying again since that code block was horrid.

    #RollBack#13.36 Gravity mover velocity rolled back to:-21.6
    UnityEngine.DebugLogHandler:Internal_Log(LogType, String, Object)
    UnityEngine.DebugLogHandler:LogFormat(LogType, Object, String, Object[])
    UnityEngine.Logger:LogFormat(LogType, String, Object[])
    UnityEngine.Debug:LogFormat(String, Object[])
    GravityMover:ApplyUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Scripts\Shared\Movement\Movers.cs:318)
    MovableUnit:OnSyncedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Scripts\Shared\Movement\MovableUnit.cs:436)
    TrueSync.TrueSyncManagedBehaviour:OnSyncedUpdate()
    TrueSync.TrueSyncManager:OnStepUpdate(List`1) (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:781)
    TrueSync.AbstractLockstep:ExecutePhysicsStep(List`1, Int32)
    TrueSync.RollbackLockstep:Rollback(Int32, Int32)
    TrueSync.RollbackLockstep:BeforeStepUpdate(Int32, Int32)
    TrueSync.AbstractLockstep:Update()
    TrueSync.TrueSyncManager:FixedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:714)

    (Filename: Z:/Projects/Atomech/project-sidescroller/Assets/Scripts/Shared/Movement/Movers.cs Line: 318)

    #RollBack#13.36 Rollback from 13.36
    UnityEngine.DebugLogHandler:Internal_Log(LogType, String, Object)
    UnityEngine.DebugLogHandler:LogFormat(LogType, Object, String, Object[])
    UnityEngine.Logger:LogFormat(LogType, String, Object[])
    UnityEngine.Debug:LogFormat(String, Object[])
    AdvancedInputModule:OnSyncedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\NetworkedInputTest\TrueSyncInputSources\AdvancedInputModule.cs:280)
    TrueSync.TrueSyncManagedBehaviour:OnSyncedUpdate()
    TrueSync.TrueSyncManager:OnStepUpdate(List`1) (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:797)
    TrueSync.AbstractLockstep:ExecutePhysicsStep(List`1, Int32)
    TrueSync.RollbackLockstep:Rollback(Int32, Int32)
    TrueSync.RollbackLockstep:BeforeStepUpdate(Int32, Int32)
    TrueSync.AbstractLockstep:Update()
    TrueSync.TrueSyncManager:FixedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:714)

    (Filename: Z:/Projects/Atomech/project-sidescroller/Assets/NetworkedInputTest/TrueSyncInputSources/AdvancedInputModule.cs Line: 280)

    IndexOutOfRangeException: Array index is out of range.
    at TrueSync.Physics2D.DynamicTree`1[TrueSync.Physics2D.FixtureProxy].GetFatAABB (Int32 proxyId, TrueSync.Physics2D.AABB& fatAABB) [0x00019] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Collision\DynamicTree.cs:285
    at TrueSync.Physics2D.DynamicTreeBroadPhase.TestOverlap (Int32 proxyIdA, Int32 proxyIdB) [0x0000a] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Collision\DynamicTreeBroadPhase.cs:226
    at TrueSync.Physics2D.ContactManager.Collide () [0x00189] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Dynamics\ContactManager.cs:374
    at TrueSync.Physics2D.World.Step (FP dt) [0x000c2] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Dynamics\World.cs:1210
    at TrueSync.Physics2DWorldManager.UpdateStep () [0x0000d] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\Physics2DWorldManager.cs:70
    at TrueSync.AbstractLockstep.ExecutePhysicsStep (System.Collections.Generic.List`1 data, Int32 syncedDataTick) [0x00000] in :0
    at TrueSync.RollbackLockstep.Rollback (Int32 rollbackTick, Int32 temporaryRollbackWindow) [0x00000] in :0
    at TrueSync.RollbackLockstep.BeforeStepUpdate (Int32 syncedDataTick, Int32 referenceTick) [0x00000] in :0
    at TrueSync.AbstractLockstep.Update () [0x00000] in :0
    at TrueSync.TrueSyncManager.FixedUpdate () [0x0006f] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:714

    (Filename: Z:/Projects/Atomech/project-sidescroller/Assets/Standard Assets/TrueSync/Physics/Farseer/Collision/DynamicTree.cs Line: 285)
  • Trying again since that code block was horrid.

    #RollBack#13.36 Gravity mover velocity rolled back to:-21.6
    UnityEngine.DebugLogHandler:Internal_Log(LogType, String, Object)
    UnityEngine.DebugLogHandler:LogFormat(LogType, Object, String, Object[])
    UnityEngine.Logger:LogFormat(LogType, String, Object[])
    UnityEngine.Debug:LogFormat(String, Object[])
    GravityMover:ApplyUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Scripts\Shared\Movement\Movers.cs:318)
    MovableUnit:OnSyncedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Scripts\Shared\Movement\MovableUnit.cs:436)
    TrueSync.TrueSyncManagedBehaviour:OnSyncedUpdate()
    TrueSync.TrueSyncManager:OnStepUpdate(List`1) (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:781)
    TrueSync.AbstractLockstep:ExecutePhysicsStep(List`1, Int32)
    TrueSync.RollbackLockstep:Rollback(Int32, Int32)
    TrueSync.RollbackLockstep:BeforeStepUpdate(Int32, Int32)
    TrueSync.AbstractLockstep:Update()
    TrueSync.TrueSyncManager:FixedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:714)

    (Filename: Z:/Projects/Atomech/project-sidescroller/Assets/Scripts/Shared/Movement/Movers.cs Line: 318)

    #RollBack#13.36 Rollback from 13.36
    UnityEngine.DebugLogHandler:Internal_Log(LogType, String, Object)
    UnityEngine.DebugLogHandler:LogFormat(LogType, Object, String, Object[])
    UnityEngine.Logger:LogFormat(LogType, String, Object[])
    UnityEngine.Debug:LogFormat(String, Object[])
    AdvancedInputModule:OnSyncedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\NetworkedInputTest\TrueSyncInputSources\AdvancedInputModule.cs:280)
    TrueSync.TrueSyncManagedBehaviour:OnSyncedUpdate()
    TrueSync.TrueSyncManager:OnStepUpdate(List`1) (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:797)
    TrueSync.AbstractLockstep:ExecutePhysicsStep(List`1, Int32)
    TrueSync.RollbackLockstep:Rollback(Int32, Int32)
    TrueSync.RollbackLockstep:BeforeStepUpdate(Int32, Int32)
    TrueSync.AbstractLockstep:Update()
    TrueSync.TrueSyncManager:FixedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:714)

    (Filename: Z:/Projects/Atomech/project-sidescroller/Assets/NetworkedInputTest/TrueSyncInputSources/AdvancedInputModule.cs Line: 280)

    IndexOutOfRangeException: Array index is out of range.
    at TrueSync.Physics2D.DynamicTree`1[TrueSync.Physics2D.FixtureProxy].GetFatAABB (Int32 proxyId, TrueSync.Physics2D.AABB& fatAABB) [0x00019] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Collision\DynamicTree.cs:285
    at TrueSync.Physics2D.DynamicTreeBroadPhase.TestOverlap (Int32 proxyIdA, Int32 proxyIdB) [0x0000a] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Collision\DynamicTreeBroadPhase.cs:226
    at TrueSync.Physics2D.ContactManager.Collide () [0x00189] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Dynamics\ContactManager.cs:374
    at TrueSync.Physics2D.World.Step (FP dt) [0x000c2] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Dynamics\World.cs:1210
    at TrueSync.Physics2DWorldManager.UpdateStep () [0x0000d] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\Physics2DWorldManager.cs:70
    at TrueSync.AbstractLockstep.ExecutePhysicsStep (System.Collections.Generic.List`1 data, Int32 syncedDataTick) [0x00000] in :0
    at TrueSync.RollbackLockstep.Rollback (Int32 rollbackTick, Int32 temporaryRollbackWindow) [0x00000] in :0
    at TrueSync.RollbackLockstep.BeforeStepUpdate (Int32 syncedDataTick, Int32 referenceTick) [0x00000] in :0
    at TrueSync.AbstractLockstep.Update () [0x00000] in :0
    at TrueSync.TrueSyncManager.FixedUpdate () [0x0006f] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:714

    (Filename: Z:/Projects/Atomech/project-sidescroller/Assets/Standard Assets/TrueSync/Physics/Farseer/Collision/DynamicTree.cs Line: 285)
  • Trying again since that code block was horrid.

    #RollBack#13.36 Rollback from 13.36
    UnityEngine.DebugLogHandler:Internal_Log(LogType, String, Object)
    UnityEngine.DebugLogHandler:LogFormat(LogType, Object, String, Object[])
    UnityEngine.Logger:LogFormat(LogType, String, Object[])
    UnityEngine.Debug:LogFormat(String, Object[])
    AdvancedInputModule:OnSyncedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\NetworkedInputTest\TrueSyncInputSources\AdvancedInputModule.cs:280)
    TrueSync.TrueSyncManagedBehaviour:OnSyncedUpdate()
    TrueSync.TrueSyncManager:OnStepUpdate(List`1) (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:797)
    TrueSync.AbstractLockstep:ExecutePhysicsStep(List`1, Int32)
    TrueSync.RollbackLockstep:Rollback(Int32, Int32)
    TrueSync.RollbackLockstep:BeforeStepUpdate(Int32, Int32)
    TrueSync.AbstractLockstep:Update()
    TrueSync.TrueSyncManager:FixedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:714)

    (Filename: Z:/Projects/Atomech/project-sidescroller/Assets/NetworkedInputTest/TrueSyncInputSources/AdvancedInputModule.cs Line: 280)

    IndexOutOfRangeException: Array index is out of range.
    at TrueSync.Physics2D.DynamicTree`1[TrueSync.Physics2D.FixtureProxy].GetFatAABB (Int32 proxyId, TrueSync.Physics2D.AABB& fatAABB) [0x00019] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Collision\DynamicTree.cs:285
    at TrueSync.Physics2D.DynamicTreeBroadPhase.TestOverlap (Int32 proxyIdA, Int32 proxyIdB) [0x0000a] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Collision\DynamicTreeBroadPhase.cs:226
    at TrueSync.Physics2D.ContactManager.Collide () [0x00189] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Dynamics\ContactManager.cs:374
    at TrueSync.Physics2D.World.Step (FP dt) [0x000c2] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Dynamics\World.cs:1210
    at TrueSync.Physics2DWorldManager.UpdateStep () [0x0000d] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\Physics2DWorldManager.cs:70
    at TrueSync.AbstractLockstep.ExecutePhysicsStep (System.Collections.Generic.List`1 data, Int32 syncedDataTick) [0x00000] in :0
    at TrueSync.RollbackLockstep.Rollback (Int32 rollbackTick, Int32 temporaryRollbackWindow) [0x00000] in :0
    at TrueSync.RollbackLockstep.BeforeStepUpdate (Int32 syncedDataTick, Int32 referenceTick) [0x00000] in :0
    at TrueSync.AbstractLockstep.Update () [0x00000] in :0
    at TrueSync.TrueSyncManager.FixedUpdate () [0x0006f] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:714

    (Filename: Z:/Projects/Atomech/project-sidescroller/Assets/Standard Assets/TrueSync/Physics/Farseer/Collision/DynamicTree.cs Line: 285)
  • Trying again since that code block was horrid.

    #RollBack#13.36 Rollback from 13.36
    UnityEngine.DebugLogHandler:Internal_Log(LogType, String, Object)
    UnityEngine.DebugLogHandler:LogFormat(LogType, Object, String, Object[])
    UnityEngine.Logger:LogFormat(LogType, String, Object[])
    UnityEngine.Debug:LogFormat(String, Object[])
    AdvancedInputModule:OnSyncedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\NetworkedInputTest\TrueSyncInputSources\AdvancedInputModule.cs:280)
    TrueSync.TrueSyncManagedBehaviour:OnSyncedUpdate()
    TrueSync.TrueSyncManager:OnStepUpdate(List`1) (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:797)
    TrueSync.AbstractLockstep:ExecutePhysicsStep(List`1, Int32)
    TrueSync.RollbackLockstep:Rollback(Int32, Int32)
    TrueSync.RollbackLockstep:BeforeStepUpdate(Int32, Int32)
    TrueSync.AbstractLockstep:Update()
    TrueSync.TrueSyncManager:FixedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:714)

    (Filename: Z:/Projects/Atomech/project-sidescroller/Assets/NetworkedInputTest/TrueSyncInputSources/AdvancedInputModule.cs Line: 280)

    IndexOutOfRangeException: Array index is out of range.
    at TrueSync.Physics2D.DynamicTree`1[TrueSync.Physics2D.FixtureProxy].GetFatAABB (Int32 proxyId, TrueSync.Physics2D.AABB& fatAABB) [0x00019] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Collision\DynamicTree.cs:285
    at TrueSync.Physics2D.DynamicTreeBroadPhase.TestOverlap (Int32 proxyIdA, Int32 proxyIdB) [0x0000a] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Collision\DynamicTreeBroadPhase.cs:226
    at TrueSync.Physics2D.ContactManager.Collide () [0x00189] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Dynamics\ContactManager.cs:374
    at TrueSync.Physics2D.World.Step (FP dt) [0x000c2] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Dynamics\World.cs:1210
    at TrueSync.Physics2DWorldManager.UpdateStep () [0x0000d] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\Physics2DWorldManager.cs:70
    at TrueSync.AbstractLockstep.ExecutePhysicsStep (System.Collections.Generic.List`1 data, Int32 syncedDataTick) [0x00000] in :0
    at TrueSync.RollbackLockstep.Rollback (Int32 rollbackTick, Int32 temporaryRollbackWindow) [0x00000] in :0
    at TrueSync.RollbackLockstep.BeforeStepUpdate (Int32 syncedDataTick, Int32 referenceTick) [0x00000] in :0
    at TrueSync.AbstractLockstep.Update () [0x00000] in :0
    at TrueSync.TrueSyncManager.FixedUpdate () [0x0006f] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:714

    (Filename: Z:/Projects/Atomech/project-sidescroller/Assets/Standard Assets/TrueSync/Physics/Farseer/Collision/DynamicTree.cs Line: 285)
  • All of the above posts were from the original entry when I tried to edit it and couldn't. I can't delete the replies. Please disregard.
  • Oh that's fine, I was think you did some automation to reproduce the case and send the feedback here hahaha.

  • IndexOutOfRangeException: Array index is out of range.
    TrueSync.Physics2D.DynamicTree`1[TrueSync.Physics2D.FixtureProxy].GetFatAABB (Int32 proxyId, TrueSync.Physics2D.AABB& fatAABB)
    TrueSync.Physics2D.DynamicTreeBroadPhase.TestOverlap (Int32 proxyIdA, Int32 proxyIdB)
    TrueSync.Physics2D.ContactManager.Collide ()
    TrueSync.Physics2D.World.Step (FP dt)
    TrueSync.Physics2DWorldManager.UpdateStep ()
    TrueSync.AbstractLockstep.ExecutePhysicsStep (System.Collections.Generic.List`1 data, Int32 syncedDataTick)
    TrueSync.AbstractLockstep.Update ()
    TrueSync.TrueSyncManager.FixedUpdate ()
    Here's another one. Completely different character this time. The side-effect was the character acted like it was grounded (contact on the bottom circle of the character) - causing it to double jump in the air. Which is a side-effect of our code letting you queue a jump input before the ground collider amkes contact, so that it can respond right away.
  • More. This time with 2 characters in the scene.


    #RollBack#30.62 Rollback from 30.62
    UnityEngine.DebugLogHandler:Internal_Log(LogType, String, Object)
    UnityEngine.DebugLogHandler:LogFormat(LogType, Object, String, Object[])
    UnityEngine.Logger:LogFormat(LogType, String, Object[])
    UnityEngine.Debug:LogFormat(String, Object[])
    AdvancedInputModule:UpdateFromTrueSync() (at Z:\Projects\Atomech\project-sidescroller\Assets\NetworkedInputTest\TrueSyncInputSources\AdvancedInputModule.cs:291)
    TrueSyncInputSource:DoSyncedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Scripts\Shared\Input\TrueSyncInputSource.cs:82)
    BaseUnit:ProcessInputSources() (at Z:\Projects\Atomech\project-sidescroller\Assets\Scripts\Shared\BaseUnit\BaseUnit.cs:408)
    BaseUnit:OnSyncedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Scripts\Shared\BaseUnit\BaseUnit.cs:364)
    TrueSync.TrueSyncManagedBehaviour:OnSyncedUpdate()
    TrueSync.TrueSyncManager:OnStepUpdate(List`1) (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:791)
    TrueSync.AbstractLockstep:ExecutePhysicsStep(List`1, Int32)
    TrueSync.RollbackLockstep:Rollback(Int32, Int32)
    TrueSync.RollbackLockstep:BeforeStepUpdate(Int32, Int32)
    TrueSync.AbstractLockstep:Update()
    TrueSync.TrueSyncManager:FixedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:724)

    (Filename: Z:/Projects/Atomech/project-sidescroller/Assets/NetworkedInputTest/TrueSyncInputSources/AdvancedInputModule.cs Line: 291)

    #RollBack#30.62 Rollback from 30.62
    UnityEngine.DebugLogHandler:Internal_Log(LogType, String, Object)
    UnityEngine.DebugLogHandler:LogFormat(LogType, Object, String, Object[])
    UnityEngine.Logger:LogFormat(LogType, String, Object[])
    UnityEngine.Debug:LogFormat(String, Object[])
    AdvancedInputModule:UpdateFromTrueSync() (at Z:\Projects\Atomech\project-sidescroller\Assets\NetworkedInputTest\TrueSyncInputSources\AdvancedInputModule.cs:291)
    TrueSyncInputSource:DoSyncedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Scripts\Shared\Input\TrueSyncInputSource.cs:82)
    BaseUnit:ProcessInputSources() (at Z:\Projects\Atomech\project-sidescroller\Assets\Scripts\Shared\BaseUnit\BaseUnit.cs:408)
    BaseUnit:OnSyncedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Scripts\Shared\BaseUnit\BaseUnit.cs:364)
    TrueSync.TrueSyncManagedBehaviour:OnSyncedUpdate()
    TrueSync.TrueSyncManager:OnStepUpdate(List`1) (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:791)
    TrueSync.AbstractLockstep:ExecutePhysicsStep(List`1, Int32)
    TrueSync.RollbackLockstep:Rollback(Int32, Int32)
    TrueSync.RollbackLockstep:BeforeStepUpdate(Int32, Int32)
    TrueSync.AbstractLockstep:Update()
    TrueSync.TrueSyncManager:FixedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:724)

    (Filename: Z:/Projects/Atomech/project-sidescroller/Assets/NetworkedInputTest/TrueSyncInputSources/AdvancedInputModule.cs Line: 291)

    IndexOutOfRangeException: Array index is out of range.
    at TrueSync.Physics2D.DynamicTree`1[TrueSync.Physics2D.FixtureProxy].GetFatAABB (Int32 proxyId, TrueSync.Physics2D.AABB& fatAABB) [0x00019] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Collision\DynamicTree.cs:285
    at TrueSync.Physics2D.DynamicTreeBroadPhase.TestOverlap (Int32 proxyIdA, Int32 proxyIdB) [0x00018] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Collision\DynamicTreeBroadPhase.cs:227
    at TrueSync.Physics2D.ContactManager.Collide () [0x00189] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Dynamics\ContactManager.cs:374
    at TrueSync.Physics2D.World.Step (FP dt) [0x000c2] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Dynamics\World.cs:1210
    at TrueSync.Physics2DWorldManager.UpdateStep () [0x0000d] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\Physics2DWorldManager.cs:70
    at TrueSync.AbstractLockstep.ExecutePhysicsStep (System.Collections.Generic.List`1 data, Int32 syncedDataTick) [0x00000] in :0
    at TrueSync.AbstractLockstep.Update () [0x00000] in :0
    at TrueSync.TrueSyncManager.FixedUpdate () [0x0006f] in Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:724

    (Filename: Z:/Projects/Atomech/project-sidescroller/Assets/Standard Assets/TrueSync/Physics/Farseer/Collision/DynamicTree.cs Line: 285)
    Going to try to capture some data in the error log when this happens (Try -> Catch, print all of the objects)
  • It appears it is trying to roll back to the same frame twice in a row.


  • The there was a proxy out of range error for either 25 or -1. (UpRear, Friendly Directed Shot(Clone))
    UnityEngine.DebugLogHandler:Internal_Log(LogType, String, Object)
    UnityEngine.DebugLogHandler:LogFormat(LogType, Object, String, Object[])
    UnityEngine.Logger:LogFormat(LogType, String, Object[])
    UnityEngine.Debug:LogErrorFormat(String, Object[])
    TrueSync.Physics2D.ContactManager:Collide() (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Dynamics\ContactManager.cs:390)
    TrueSync.Physics2D.World:Step(FP) (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Dynamics\World.cs:1210)
    TrueSync.Physics2DWorldManager:UpdateStep() (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\Physics2DWorldManager.cs:70)
    TrueSync.AbstractLockstep:ExecutePhysicsStep(List`1, Int32)
    TrueSync.AbstractLockstep:Update()
    TrueSync.TrueSyncManager:FixedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:724)

    (Filename: Z:/Projects/Atomech/project-sidescroller/Assets/Standard Assets/TrueSync/Physics/Farseer/Dynamics/ContactManager.cs Line: 390)

    The there was a proxy out of range error for either 35 or -1. (CenterRear, Friendly Directed Shot(Clone))
    UnityEngine.DebugLogHandler:Internal_Log(LogType, String, Object)
    UnityEngine.DebugLogHandler:LogFormat(LogType, Object, String, Object[])
    UnityEngine.Logger:LogFormat(LogType, String, Object[])
    UnityEngine.Debug:LogErrorFormat(String, Object[])
    TrueSync.Physics2D.ContactManager:Collide() (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Dynamics\ContactManager.cs:390)
    TrueSync.Physics2D.World:Step(FP) (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Physics\Farseer\Dynamics\World.cs:1210)
    TrueSync.Physics2DWorldManager:UpdateStep() (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\Physics2DWorldManager.cs:70)
    TrueSync.AbstractLockstep:ExecutePhysicsStep(List`1, Int32)
    TrueSync.AbstractLockstep:Update()
    TrueSync.TrueSyncManager:FixedUpdate() (at Z:\Projects\Atomech\project-sidescroller\Assets\Standard Assets\TrueSync\Unity\TrueSyncManager.cs:724)

    (Filename: Z:/Projects/Atomech/project-sidescroller/Assets/Standard Assets/TrueSync/Physics/Farseer/Dynamics/ContactManager.cs Line: 390)
    Hrmm... it appears the FixtureB.Proxies[IndexB].ProxyId is negative one for the missile that I created with TrueSync.SyncedInstantiate
  • Yep, all of the errors related to the missing proxyID are connected to a missile. Going to take a pass on the missile code tmrw. T_T
  • Did you find something there? Rollbacks can happen more than one time per frame, it will depend on your rollback window settings.
  • No, I still haven't. I just confirmed that the worst case scenarios were related to dynamically created bodies. I got stuck on the 'disconnect before start' problem and didn't get further into this bug.
  • Did you try to disable rollbacks and check if the problem is happening anyways? Rollback adds some complexity, so it could be a bug there.
  • At this point, I am unable to consistently play multiplayer together with two clients due to them desyncing almost immediately. Until that's fixed, I can't dig deeper into this issue.
  • Humm I got it @Xelnath, good luck on that issue, come back here any problem.
  • I set my Panic window to 1000 - and now the clients seem to have enough time to sync up about 60/40% of the time.

    Now I am getting this error which I've never seen before:

    The there was a proxy out of range error for either 5 or -1. (Panels (UnityEngine.Transform) - Ramp, Friendly Directed Shot(Clone) (UnityEngine.GameObject))
    The there was a proxy out of range error for either 5 or -1. (Panels (UnityEngine.Transform) - Ramp, Friendly Directed Shot(Clone) (UnityEngine.GameObject))
    The there was a proxy out of range error for either -1 or 87. (Friendly Directed Shot(Clone) (UnityEngine.GameObject), Friendly Directed Shot(Clone) (UnityEngine.GameObject))
    The there was a proxy out of range error for either -1 or 87. (Friendly Directed Shot(Clone) (UnityEngine.GameObject), Friendly Directed Shot(Clone) (UnityEngine.GameObject))

    UnityEngine.Debug:LogErrorFormat(String, Object[])
    TrueSync.Physics2D.ContactManager:Collide()
    TrueSync.Physics2D.World:Step(FP)
    TrueSync.Physics2DWorldManager:UpdateStep()
    TrueSync.AbstractLockstep:ExecutePhysicsStep(List`1, Int32)
    TrueSync.RollbackLockstep:Rollback(Int32, Int32)
    TrueSync.RollbackLockstep:BeforeStepUpdate(Int32, Int32)
    TrueSync.AbstractLockstep:Update()
    TrueSync.TrueSyncManager:FixedUpdate()
  • Ooh, wait, I just realized this is a Try/Catch block I setup way back when I created the thread to catch this situation.

    Good, good, this will help track things down. At least it lets me know exactly when it happens.
  • Interesting @Xelnath, as more we the game get complex we got strange errors :D
Sign In or Register to comment.