Search Issue Tracker
Fixed in 2020.1.X
Votes
0
Found in
2020.1.0a2
2020.1.0a9
Issue ID
1199278
Regression
Yes
Serializable generic class causes "You are trying to create a MonoBehaviour using the 'new' keyword." when class is declared
How to reproduce:
1. Open attached project "playground-2020.1a.zip" and scene "SampleScene"
2. Open "GenericBehaviour" script
3. Make any changes (make sure it compiles without errors)
4. Observe Console window
Expected result: no warnings are thrown
Actual result: "You are trying to create a MonoBehaviour using the 'new' keyword." warning is thrown
Reproducible with: 2020.1.0a2, 2020.1.0a15
Not reproducible with: 2018.4.13f1, 2019.2.14f1, 2019.3.0f1, 2019.2.0a1
Could not test with: 2017.4 (due to MonoBehaviour class not detected, errors in Console window)
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
- The Scene View becomes gray and "NullReferenceException" errors are thrown when attaching the Unity Editor process to RenderDoc
- Memory usage rapidly rises when changing colors in the color wheel
- Physically Based Sky's Horizon and Zenith Tint Color Selection Bars don't have immediate access to color pickers
- EmptyAdditionalLightShadowmapTexture leaks from memory when URP quality level is changed using QualitySettings.SetQualityLevel
- Referenced ScriptableObject field does not get updated and cannot be set to "None" when there are no Objects of that type
Resolution Note (fix version 2020.1):
Fixed in 2020.1.0a22