Prediction.CorrectHistory: reuse 'key'. same but cleaner.

This commit is contained in:
mischa 2024-01-10 15:41:33 +01:00
parent 0fd342e6a9
commit 8473eff1ff

View File

@ -183,7 +183,7 @@ public static T CorrectHistory<T>(
// //
// not saving it would also result in objects flying towards // not saving it would also result in objects flying towards
// infinity when using sendInterval = 0. // infinity when using sendInterval = 0.
stateHistory[entry.timestamp] = entry; stateHistory[key] = entry;
// debug draw the corrected state // debug draw the corrected state
// Debug.DrawLine(last.position, entry.position, Color.cyan, lineTime); // Debug.DrawLine(last.position, entry.position, Color.cyan, lineTime);