当我尝试迁移到 cannon-es 时,我在step()
函数中得到一个错误:
Uncaught TypeError: bodies[i].integrate is not a function
step()
函数是:
this.physicsWorld.step(1 / 60, this.experience.time.delta, 3)
和step()
函数的文档:https://pmndrs.github.io/cannon-es/docs/cles/world.html#step
我找不到任何错误。这个错误是什么意思?
我忘了在一个文件中导入 cannon-es 而不是 cannonjs,所以我使用了两个库的混合。
本站系公益性非盈利分享网址,本文来自用户投稿,不代表边看边学立场,如若转载,请注明出处
评论列表(31条)