Merged
Conversation
0xFA11
reviewed
Aug 16, 2021
Comment on lines
+12
to
+22
| [Test] | ||
| [TestCase(0d, 0)] | ||
| [TestCase(5d, 0)] | ||
| [TestCase(-5d, 0)] | ||
| [TestCase(0d, -20)] | ||
| [TestCase(5d, int.MinValue)] | ||
| [TestCase(-5d, -1)] | ||
| public void TestFailCreateInvalidTime(double time, int tickrate) | ||
| { | ||
| Assert.Throws<UnityEngine.Assertions.AssertionException>(() => new NetworkTime(tickrate, time)); | ||
| } |
Contributor
There was a problem hiding this comment.
are we saying, they should always be positive?
Contributor
Author
There was a problem hiding this comment.
Time values can be negative. With the idea that you can add a negative time to a positive time etc. But tickrate must always be positive. A 0 or negative tick rate does not make sense.
Contributor
There was a problem hiding this comment.
would you like to comment this or something similar explaining "why these values are invalid?" inline? :)
0xFA11
approved these changes
Aug 16, 2021
SamuelBellomo
added a commit
that referenced
this pull request
Aug 23, 2021
…nsform * develop: (21 commits) test: adding more details to multiprocess readme (#1050) refactor!: convert NetworkTransform.NetworkState to `struct` (#1061) fix: networkmanager destroy on app quit (#1011) feat: snapshot, using unreliable packets, now that the underlying foundation supports it. Only merge after #1062 (#1064) feat: snapshot. Fully integrated despawn, mtt-1092, mtt-1056 (#1062) fix: eliminate bad use-after-free(destroy) pattern (#1068) chore: cleanup meta files for empty dirs (#1067) chore: minor MLAPI to Netcode rename (#1065) feat: report network behaviour name to the profiler (#1058) fix: player movement (#1063) test: Add unit tests for NetworkTime properties (#1053) chore: remove authority & netvar perms from NetworkTransform (#1059) feat: networktransform pos/rot/sca thresholds on state sync (#1055) feat: expose network behaviour type name internally (#1057) chore: remove all the old profiling code (#1048) fix: if-guard `NetworkManager.__rpc_name_table` access (#1056) fix: Disabling fixedupdate portion of SpawnRpcDespawn test because it's failing for known reasons that will be fixed in the IMessage refactor. (#1049) feat: Implement metrics for the new network profiler (#960) chore!: change package name & asmdefs (#1026) feat: per axis networktransform state sync (+bitwise state comp) (#1042) ... # Conflicts: # com.unity.netcode.gameobjects/Prototyping/NetworkTransform.cs
3 tasks
mollstam
pushed a commit
to Keepsake-Games/com.unity.netcode.gameobjects
that referenced
this pull request
Feb 13, 2023
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds unit tests for NetworkTime to test that all properties are working correctly. NetworkTime/Tick has 100% code coverage now 👍