mirror of
https://github.com/MirrorNetworking/Mirror.git
synced 2024-11-18 19:10:32 +00:00
PredictedRigidbody: syntax
This commit is contained in:
parent
597fd933c4
commit
07eba2dfc6
@ -425,8 +425,8 @@ void FixedUpdate()
|
|||||||
{
|
{
|
||||||
// on clients (not host) we record the current state every FixedUpdate.
|
// on clients (not host) we record the current state every FixedUpdate.
|
||||||
// this is cheap, and allows us to keep a dense history.
|
// this is cheap, and allows us to keep a dense history.
|
||||||
if (isClientOnly)
|
if (!isClientOnly) return;
|
||||||
{
|
|
||||||
// OPTIMIZATION: RecordState() is expensive because it inserts into a SortedList.
|
// OPTIMIZATION: RecordState() is expensive because it inserts into a SortedList.
|
||||||
// only record if state actually changed!
|
// only record if state actually changed!
|
||||||
// risks not having up to date states when correcting,
|
// risks not having up to date states when correcting,
|
||||||
@ -447,7 +447,6 @@ void FixedUpdate()
|
|||||||
|
|
||||||
RecordState();
|
RecordState();
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
// manually store last recorded so we can easily check against this
|
// manually store last recorded so we can easily check against this
|
||||||
// without traversing the SortedList.
|
// without traversing the SortedList.
|
||||||
|
Loading…
Reference in New Issue
Block a user