Search Issue Tracker
Fixed
Fixed in 1.3.X - Entities
Votes
0
Found in [Package]
1.2.0 - Entities
1.3.X - Entities
Issue ID
ECSB-1060
Regression
Yes
"SystemAPI.GetSingletonBuffer" method's "isReadOnly" argument is ignored when generating ISystem code
How to reproduce:
1. Open the “BugReports“ project
2. In the Project window navigate and open the “Assets/SignletonBufferSystem.cs” script
3. Wait until IDE indexes all the files
4. Select the class name string “SingletonBufferSystem”
5. Right-click on it then from the context menu select “Go to declaration” or press F12
6. Observe lines 12 and 14
Expected result: The “GetSingletonBuffer” method arguments are not empty
Actual result: The “GetSingletonBuffer” method arguments are empty
Reproduced with: 1.2.0-exp.3 (6000.0.0b15), 1.2.0 (2022.3.25f1, 6000.0.0b15)
Not reproduced with: 1.0.16 (2022.3.25f1), 1.1.0-pre.3 (6000.0.0b15)
Reproduced on: Windows 11
Not reproduced on: No other environment tested
IDE reproduced on: JetBrains Rider
IDE could not test on: Visual Studio (Could not find a way to inspect the generated code)
Workaround: Use “SystemAPI.TryGetSingletonBuffer<SingletonBuffer>(out var buffer, true)” instead of “SystemAPI.GetSingletonBuffer<SingletonBuffer>(true)”
Note: More explanation on the expected and actual results is provided in the internal comments
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
- Silent crash when clicking in Scene View in a specific project
- The Player renders black on a Quest headset when MSAA, Post Processing, and Spacewarm depth submission are enabled
- Graphics Compositor breaks Unity rendering when the "Output Camera" is changed to a scene Camera and one Camera SubLayer is active
- The Editor freezes on RenderGraphViewer.Repaint when entering too many characters in search fields without character limits
- Adding a new SubLayer in Graphics Compositor renders BaseLayer darker and makes it flicker
Resolution Note (fix version 1.3.X - Entities):
SystemAPI.GetSingletonBuffer now correctly passed the IsReadOnly param