Commit e7b14c2
authored
fix: NetworkBehaviour inspector view exceptions when using a distributed authority network topology (#3578)
This PR addresses an issue where `NetworkBehaviour` could throw an
exception if viewed within the inspector view during a distributed
authority network topology based session and using a DAHost that is not
the authority of the associated `NetworkObject`.
This PR also addresses the issue where the authority does not have
editable inspector view fields when viewed by the authority during a
distributed authority session.
## Changelog
-Fixed: Issue where viewing a `NetworkBehaviour` with one or more
`NetworkVariable` fields could throw an exception if running a
distributed authority network topology with a local (DAHost) host and
viewed on the host when the host is not the authority of the associated
`NetworkObject`.
-Fixed: Issue when using a distributed authority network topology and
viewing a `NetworkBehaviour` with one or more `NetworkVariable` fields
in the inspector view would not show editable fields.
## Testing and Documentation
- No tests have been added.
- No documentation changes or additions were necessary.
- Manually testing this is required to validate.
<!-- Uncomment and mark items off with a * if this PR deprecates any
API:
### Deprecated API
- [ ] An `[Obsolete]` attribute was added along with a `(RemovedAfter
yyyy-mm-dd)` entry.
- [ ] An [api updater] was added.
- [ ] Deprecation of the API is explained in the CHANGELOG.
- [ ] The users can understand why this API was removed and what they
should use instead.
-->
## Backport
This is a v2.x distributed authority specific issue. No back port is
needed.
<!-- If this is a backport:
- Add the following to the PR title: "\[Backport\] ..." .
- Link to the original PR.
If this needs a backport - state this here
If a backport is not needed please provide the reason why.
If the "Backports" section is not present it will lead to a CI test
failure.
-->1 parent 0e04623 commit e7b14c2
File tree
2 files changed
+28
-5
lines changed- com.unity.netcode.gameobjects
- Runtime/Core
2 files changed
+28
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
13 | 26 | | |
14 | 27 | | |
15 | 28 | | |
| |||
Lines changed: 15 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
529 | 529 | | |
530 | 530 | | |
531 | 531 | | |
532 | | - | |
533 | | - | |
534 | | - | |
535 | | - | |
536 | | - | |
| 532 | + | |
| 533 | + | |
| 534 | + | |
| 535 | + | |
| 536 | + | |
| 537 | + | |
| 538 | + | |
| 539 | + | |
| 540 | + | |
| 541 | + | |
| 542 | + | |
| 543 | + | |
| 544 | + | |
| 545 | + | |
| 546 | + | |
537 | 547 | | |
538 | 548 | | |
539 | 549 | | |
| |||
0 commit comments