[LayaAir3]3.0.9物理引擎获取碰撞点报错

protected onTriggerEnter(other: Laya.ColliderBase, self: Laya.ColliderBase, contact:any) {
console.log(contact.getHitInfo())
}
报错信息:
ModuleDef.ts:41 Uncaught TypeError: Cannot read properties of undefined (reading 'b2WorldManifold')
at contact.getHitInfo (ModuleDef.ts:41:28)
已邀请:

dsk4120

赞同来自:

let manifold = new Laya.Physics.I.box2d.b2WorldManifold()
contact.GetWorldManifold(manifold)
console.log(manifold)
通过面的获取碰撞点坐标,都是(0,0)

要回复问题请先

商务合作
商务合作