Search Issue Tracker
Fixed
Fixed in 2022.3.5f1, 2023.1.4f1, 2023.2.0a22
Votes
2
Found in
2022.2.7f1
2023.1.0b4
2023.2.0a2
Issue ID
UUM-27260
Regression
No
List.Capacity is used instead of count in ”SetSharedMaterials”
How to reproduce:
# Open the attached project "SetMaterialsBug.zip"
# Enter Play Mode
Expected results: No errors are thrown
Actual results: "Unexpected number of materials!" is thrown in the Console window
Reproducible with: 2022.2.7f1, 2023.1.0b4, 2023.2.0a2
Could not test with: 2020.3.45f1, 2021.3.18f1 ('Renderer' does not contain a definition for 'SetMaterials')
Reproducible on: Windows 10
Comments (1)
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
- Error "Objects are trying to be loaded during a domain backup. This is not allowed as it will lead to undefined behaviour!" when entering Play Mode with the PBR Sky Shader Graph created in Project
- Custom Property and Function Labels at the top of the Graph Inspector go out of bounds and are not truncated when String is long
- Warning "Full dialog message:" is logged when the project is upgraded to a newer version
- A 404 page is opened when selecting "Open Documentation" for any of the HDRP specific Input Nodes in Shader Graph
- A 404 page is opened when selecting "Open Documentation" on the URP Sample Buffer Node in Shader Graph
peturdarri
Feb 15, 2023 11:26
To clarify the description, this happens when trying to set fewer materials on a renderer than there currently are on it. It applies to both SetMaterials and SetSharedMaterials.