Undefined is not an object (evaluating 'data.length')

An odd error I got… and the worst part is that none of my scripts have anything called “data.length”…

Project:
https://playcanvas.com/editor/scene/1439135

Thank you for any help!

chunk.verts is undefined
game.js: 29

Thank you @jejelee98!
However, after fixing that, I got some other issues that other people seem not to have encountered before:
“ ASSERT FAILED:

Vertex stream NORMAL has 307 vertices, which does not match already set streams with 1228 vertices.

this._material.addMeshInstanceRef is not a function. (In ‘this._material.addMeshInstanceRef(this)’, ‘this._material.addMeshInstanceRef’ is undefined)”

I’m using my phone, so there may be something I am not seeing…

try
“this.material.resource” at game.js line 33
and using chrome console
it will solve almost 99% of your problem

Thank you @jejelee98! That fixed the texture problem. I also did other miscellaneous fixes that allowed for the application to push through an odd “vertex buffer format” issue. But now, the
ASSERT FAILED:

Vertex stream NORMAL has 307 vertices, which does not match already set streams with 1228 vertices.
Is still an issue. Do I need to allocate memory for the Normal vectors? Because the “calculateNormals()” functions made WAY too many normal vectors (think 100 million), I put them in myself if you look at line 68. Either way, it is broken.

I must be missing something, obviously.
Maybe @Leonidas, @yaustar, or @mvaligursky would know a thing or two?

Thank you.

EDIT: I noticed that the streams it is asking for are always 4 times the size of what is there.