Search Issue Tracker
Fixed in 0.4.0
Votes
0
Found in [Package]
preview.1-0.0.2
Issue ID
1215535
Regression
No
[Unity NetCode] Console error appears when generating Ghost Authoring component code
Steps to reproduce:
1. Create a new project
2. In the Hierarchy window, create and select an empty GameObject
3. In the Inspector window, press "Add Component"
4. Add "Ghost Authoring Component" component
5. In the Inspector window, press "Update component list"
6. Change the Default Client Instantiation Client Type to "Owner Predicted"
7. Change the Predicting player network id to "Unity.Transforms.Rotation.Value"
8. Press "Generate Code"
Expected outcome: No error messages appear in the Console window
Actual outcome: Error "Operator '==' cannot be applied to operands of type 'quaternion' and 'int'" appears in the Console window
Reproducible with: 2019.3.4f1, 2020.1.0b1, 2020.2.0a2 (Unity NetCode versions preview.1-0.0.2, preview.0-0.0.4)
Could not test with: Unity versions 2017.4, 2018.4, 2019.2, 2019.3.0b10 (Unity NetCode is not available), Unity NetCode package version preview.6-0.1.0 (Other console errors)
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- UI Toolkit 'background-size' property is not fully animatable
- Moving the Scrollbar via clicking no longer works after the first-click when page size is too small
- Elements in UI Builder Viewport are displayed incorrectly when Editor UI Scaling is set to 125%
- Prefab referencing a script is not shown in the Search window's Project tab when using "Find References In Project"
- Scroll view sensitivity remains unchanged when modifying the "--unity-metrics-single_line-height" value
sachanhardik
Mar 21, 2020 17:53
The issue you are bringing up is not a bug. Player Network ID of a Ghost is supposed to be an int but rotation is quaternion. To overcome this issue, Create your own component with a player ID field and use it has Predicting player network id.
Unity could add type check in Inspector.