Commit Graph

6102 Commits

Author SHA1 Message Date
mischa
99bd93b95e fix(Prediction): disable setting scale for joints since it causes issues with parenting 2024-09-21 16:29:37 -04:00
MrGadget
3d7ef0cc60 fix: Safer version for FindAnyObjectByType (#3765)
Unity docs are a mess on when FindAnyObjectByType was implemented:
- 2021.3 says it is
- 2022.1 says it's not
- 2022.2 says it is
2024-09-21 16:29:37 -04:00
mischa
8094f88469 fix(Prediction): ConfigurableJoints' range of motion is now moved correctly 2024-09-21 16:29:37 -04:00
mischa
fb13fa37e2 fix(PredictedRigidbody): reduce-send-rate considers angular velocity now too! 2024-09-21 16:29:37 -04:00
mischa
449c33a694 Prediction: sync delta rotations too [FakeByte] 2024-09-21 16:29:37 -04:00
mischa
e7c8898679 Prediction: only set velocity if not kinematic 2024-09-21 16:29:36 -04:00
mischa
54c8caac54 Prediction: better motion smoothing time 2024-09-21 16:29:36 -04:00
mischa
05787f3853 Prediction: sync angularVelocity too 2024-09-21 16:29:36 -04:00
mischa
6cb4017deb perf(Prediction): ghosts-on-demand(!) 2024-09-21 16:29:36 -04:00
MrGadget
ee97a8bd65 CanvasNetworkManagerHUD: fixed indent 2024-09-21 16:29:36 -04:00
mischa
205cbc2d63 PredictedRigidbody: add OnBeforeApplyState callback 2024-09-21 16:29:36 -04:00
MrGadget
136c1d2b30 feat(NetworkRigidbody): Default Sync Direction = Client To Server (#3764)
- This is done in Reset so Network Behaviour isn't effected.
- This will not change components already in place on objects / prefabs unless user manually chooses Reset in the inspector.
2024-09-21 16:29:36 -04:00
MrGadget
0821e56105 fix(SWT): Improved logging in ClientHandshake
- Added hint to check Server Roles for handshake key mismatches
2024-09-21 16:29:36 -04:00
MrGadget
e60d3bf382 feat(NetworkAnimator): Default Sync Direction = Client To Server
- This is done in Reset so Network Behaviour isn't effected.
- This will not change NA components already in place on objects / prefabs unless user manually chooses Reset in the inspector.
2024-09-21 16:29:36 -04:00
Robin Rolf
bd7b6fe038 breaking: perf: change NB.syncVarDirtyBits to field (#3762)
@miwarnec saw the property showing up while profiling. Very much unnecessary, so lets change that to a field.
BREAKING: Changed NetworkBehaviour.syncVarDirtyBits from a "get-only" property to a field
2024-09-21 16:29:36 -04:00
mischa
7b50cd5197 perf(PredictedRigidbody): OnSerialize faster 2024-09-21 16:29:36 -04:00
mischa
d4e03d9463 fix(PredictedRigidbody): fix host mode [FakeByte] 2024-09-21 16:29:36 -04:00
mischa
d69d126672 fix(PredictedRigidbody): only show 'hard correcting because too old' warning if older than entire state history limit. not when starting to record only 2-3 entries yet. 2024-09-21 16:29:36 -04:00
mischa
1d5a5008bc Prediction: expose physics copy components to inheriting classes 2024-09-21 16:29:36 -04:00
mischa
81d14068a4 perf(PredictedRigidbody): reduce sends to 1 Hz while idle(!) 2024-09-21 16:29:36 -04:00
mischa
565858f1ad perf(PredictedRigidbody): only record state if changed(!) 2024-09-21 16:29:36 -04:00
MrGadget
e5dbf0dcda fix(NetworkManager): FinishStartHost-Don't force localhost (#3759) 2024-09-21 16:29:36 -04:00
JesusLuvsYooh
c17ebbc0f4 feat: NT-UR bit flag changed detection to lower bandwidth usage. (#3721)
* feat: NT-UR bit flag changed detection to lower bandwidth usage.

Also major credits to our Ninja.

* Tooltip updated

* fix: NT-Unreliable Quaternion Compression Fix

Credits to ninja of course :D

* NT-U new improvements

Credits to Ninja

* Nothing to see here..

* Added comment to Quat Rotation Fix

* Sensitivity check to improve value comparisons.

Without this, X 0 and X -4.955753E-07 (0) would trigger as a change of value.
Helps epsilon/floating point inaccuracies.

* Moved around checks.

rotationChanged not needed now for non-compressed bool, as we check individual rotation sensitivity changes.
We can move this inside quat compress check.

* Use Rot/All, not just RotX as a compress changed flag.

* Set Just Rot.

* Updated Reset to ResetState

* Fixing PR 3571/3572/3572 in this new bitflag branch

---------

Co-authored-by: ninjakickja <80569286+ninjakickja@users.noreply.github.com>
2024-09-21 16:29:36 -04:00
MrGadget
c54bd2c4f1 SyncDictionary: Fixed typo in comment 2024-09-21 16:29:36 -04:00
James Frowen
7671bde0bf fix(NetworkClient): Call NetworkTime.SendPing from OnTransportConnected (#3686)
* fix: fixing time not being sent on connect

client does not send ping if connecting to server within 2 seconds of starting, the new PingNow function will tell client to send the message right away instead of after lastPingTime+PingInterval

* Update Assets/Mirror/Core/NetworkTime.cs

* Update Assets/Mirror/Core/NetworkTime.cs

* Update Assets/Mirror/Core/NetworkClient.cs

* Update Assets/Mirror/Core/NetworkTime.cs

---------

Co-authored-by: MrGadget <9826063+MrGadget1024@users.noreply.github.com>
2024-09-21 16:29:36 -04:00
MrGadget
c411a3fa4c NetworkTime: SendPing method added. 2024-09-21 16:29:36 -04:00
mischa
1f012583f6 Prediction: warn about not readable meshes 2024-09-21 16:29:36 -04:00
MrGadget
21df956789 NetworkManager: fixed comment 2024-09-21 16:29:36 -04:00
MrGadget
cd358630ff fix(MultiplexTransport): Use TryGetValue for Lookups (#3758) 2024-09-21 16:29:36 -04:00
mischa
77469f5201 fix typos 2024-09-21 16:29:36 -04:00
MrGadget
9d5b66a64f KcpTransport: fixed ToString to match other transports 2024-09-21 16:29:36 -04:00
MrGadget
af4d8e789e fix(MultiplexTransport): Fixed log output 2024-09-21 16:29:36 -04:00
mischa
2becc2c01c ThreadLog: more obvious prefix! 2024-09-21 16:29:36 -04:00
Robin Rolf
e4e23afd9c perf(Extensions): Add shim for transform.GetPositionAndRotation (#3755)
Doesn't exist in unity versions 2021.2 or earlier
2024-09-21 16:29:36 -04:00
mischa
b403405c85 perf(PredictedRigidbody): next round of optimizations 2024-09-21 16:29:36 -04:00
MrGadget
e220e9e8f8 fix(MultiplexTransport): Better Startup Logging 2024-09-21 16:29:36 -04:00
MrGadget
1b17f582c5 Added missing meta 2024-01-29 02:22:46 -05:00
MrGadget
f4a416ab80 Merged master 2024-01-29 02:15:31 -05:00
mischa
2b92ac7674 perf(Prediction): optimize ghosts. deep profiling: 93 objects before=0.08ms after =0.03ms! 2024-01-28 12:41:13 +01:00
mischa
1899539e03 perf(Prediction): optimize LateUpdate because this shows in profiler! deep profiling: 93 objects, before=0.54ms, after=0.22ms => 2.5x faster! 2024-01-28 12:29:18 +01:00
mischa
f926514a6e perf(Prediction): cache .transform getter because this is performance critical 2024-01-28 12:29:18 +01:00
mischa
5e56b96f43 syntax 2024-01-28 12:29:18 +01:00
mischa
44338c5551 Prediction: rename DestroyCopies to DestroyGhosts for consistency 2024-01-28 12:29:18 +01:00
Justin Nolan
24c0c9ed3f
Add network mesages to lookup dict in network client replace handler (#3754) 2024-01-28 11:09:47 +01:00
Justin Nolan
1c365fc3d5
Add network messages to lookup dict in network server replace handler (#3753) 2024-01-28 11:09:35 +01:00
mischa
2c603fd406 PredictedRigidbody: improve logging 2024-01-27 11:47:34 +01:00
mischa
86805e82d2 Edgegap Hosting: updated to latest version for fixes and Websocket support 2024-01-27 10:56:42 +01:00
MrGadget
7a2cae3cfd NetworkBehaviour: Improved comments 2024-01-26 02:02:53 -05:00
MrGadget
061e49acca PredictionUtils: Fixed pre-Unity 2020.3 errors 2024-01-25 09:50:46 -05:00
MrGadget
5616f8c5a0 PredictionUtils: Fixed pre-Unity 2022.3 errors 2024-01-25 09:35:02 -05:00