Search Issue Tracker
Fixed
Fixed in 2021.3.25f1, 2022.3.1f1, 2023.2.0a11, 2023.3.0a2
Votes
3
Found in
2021.3.19f1
2022.2.7f1
2022.3.0f1
2023.1.0b5
2023.2.0a3
Issue ID
UUM-27587
Regression
Yes
"Resources.FindObjectsOfTypeAll(typeof(Material)).Length" increases every time when entering/exiting Play Mode
Reproduction steps:
1. Open the “MaterialCount“ project
2. Open the “SampleScene” scene
3. While observing the Console enter and exit Play Mode 4 times
Expected result: material count does not increase overall
Actual result: material count increases after each time
Reproduced in: 2021.2.0a16, 2021.3.19f1, 2022.2.7f1, 2023.1.0b5, 2023.2.0a3
Not reproduced in: 2020.3.45f1, 2021.2.0a15
Reproduced using: macOS 13.0.1 (Intel), Windows 10 (by the reporter)
Notes:
1. Reproduced with URP and HDRP
2. Not reproduced with Built-in RP
3. In 2021.2.0a16 it increases by 2 after each time but in the latest versions, it increases by ~8
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
- Unity CIL Linker fails on Player build when persistent listeners have "<" and ">" in their XML attribute names
- ”Lighting data asset ‘LightingData’ is incompatible with the current Unity version…” warnings are thrown when saving Indoors (URP) and Outdoors (URP) Scenes as Scene Templates
- [iOS] The screen blinks when transitioning from custom to Unity splash screen
- [macOS] ”Ignoring depth surface load action as it is memoryless” warnings are thrown when taking Game View Snapshot
- UI Builder Inspector scrolls back up when changes on an expanded but not fully displayed Inspector tab are saved
Resolution Note (fix version 2023.2.0a11):
This bug got split up internally so this fix in 2023.2.0a11 covers only the leaks in the core package and a test to catch them in the future
Resolution Note (fix version 2022.3.1f1):
Fixed in 2022.3.1f1
Resolution Note (fix version 2021.3.25f1):
Fixed in 2021.3.25f1