Skip to content

Commit 3d37086

Browse files
fix: prediction warnings showing incorrect values
When first prediction error was detected, all warnings for the object with incorrect state appearing after the first one could based on incorrect values in some cases
1 parent 8f7cb80 commit 3d37086

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

Runtime/Behaviour/ElympicsBehaviour.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -360,8 +360,12 @@ internal bool AreStatesEqual(byte[] data1, byte[] data2, long tick)
360360
ElympicsLogger.LogWarning($"State not equal on field {_backingFieldsNames[backingField]} of {componentName} component attached to {gameObject.name} game object with network ID: {networkId} in history tick {tick}. Last simulated tick: {Elympics.Tick}. State in history: '{difference1}' received state: '{difference2}'.", this);
361361
#endif
362362
areEqual = false;
363+
break;
363364
}
364365
}
366+
367+
if (!areEqual)
368+
break;
365369
}
366370
_ = _memoryStream1.Seek(0, SeekOrigin.Begin);
367371
_ = _memoryStream2.Seek(0, SeekOrigin.Begin);

0 commit comments

Comments
 (0)