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
- Rigidbody2D.Slide API does not have the needed configuration when creating a 2D Top-Down character controller
- Opening reference for "Playables"component redirects to a missing page
- Sprite Renderer image is changed when switching Mask Interaction and changing Sprite to a shared Sprite
- An unsigned integer is not compared with an integer correctly in player when using IL2CPP backend
- Graphical artifacts are being rendered in Scenes that are loaded during run-time when GPU Resident Drawer is turned on
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.