I’m trying to generate a procedural mesh but it keeps logging an error to the console that doesn’t actually explain what the error is.
UnityEngine.Component:GetComponent(Type)
UnityEngine.Component:GetComponent() (at C:\BuildAgent\work\6bc5f79e0a4296d6\Runtime\ExportGenerated\Editor\BaseClass.cs:630)
AnandamideSeedObject:setVertexPositions() (at Assets\Scripts\AnandamideSeedObject.cs:3327)
AnandamideSeedObject:ThreadedGenerateSeed() (at Assets\Scripts\AnandamideSeedObject.cs:5040)
The line of code it references in my class is
GetComponent().mesh = finalMesh;
The object has a meshfilter. When I put the offending line in the Awake() function, it instead gives me this error on
finalMesh.vertices = finalPositions;
or if I precede that line with a usage of finalMesh.vertexCount the error references that line.
komatii