This repository was archived by the owner on Jun 28, 2026. It is now read-only.
Fix calling Dirty+DiryField on same tick#129
Closed
Illiux wants to merge 3 commits into
Closed
Conversation
This commit changes IComponentDelta to hold the last tick of a generic dirty rather than the last tick of any field modification. Additionally, the bitset returned via GetModifiedFields (now GetModifiedAspects) has been extended to ulong and the high bit used to indicate an unclassified update. This approach is safer for consumers because it causes the lack of explicit handling for an unclassified update to surface as a field update to an unknown field. In the future, it would also be reasonable to use other high bits if we wanted to represent more specific change kinds. Also, I left the 32 field limit as-is in this commit, effectively leaving the remaining 31 bits reserved. Finally, while I was in here, I fixed what as far as I could determine was a pervasive and mostly harmless off-by-one error where we were sending updates if the modification occured on the same tick as fromTick. That should be unnecessary as fromTick has already been acknowledged by the client. fixes space-wizards/RobustToolbox#6524
metalgearsloth
approved these changes
Jun 23, 2026
metalgearsloth
left a comment
Contributor
There was a problem hiding this comment.
tentative because gamestate scares me.
Comment on lines
+277
to
+278
| { | ||
| var serverOpts = new ServerIntegrationOptions { Pool = false }; |
Contributor
There was a problem hiding this comment.
Any reason it doesn't pool?
Member
|
Could you move this PR to the old repository here https://github.com/space-wizards/RobustToolbox ? |
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
This commit changes IComponentDelta to hold the last tick of a generic dirty rather than the last tick of any field
modification. Additionally, the bitset returned via GetModifiedFields (now GetModifiedAspects) has been extended to
ulong and the high bit used to indicate an unclassified update. This approach is safer for consumers because it
causes the lack of explicit handling for an unclassified update to surface as a field update to an unknown field.
In the future, it would also be reasonable to use other high bits if we wanted to represent more specific change kinds.
Also, I left the 32 field limit as-is in this commit, effectively leaving the remaining 31 bits reserved.
Finally, while I was in here, I fixed what as far as I could determine was a pervasive and mostly harmless off-by-one
error where we were sending updates if the modification occured on the same tick as fromTick. That should be unnecessary
as fromTick has already been acknowledged by the client. That is, unless I missed something of course.
fixes space-wizards/RobustToolbox#6524