刚体的rigidBody对象怎么获取

如题,按官方文档这样写代码,程序报错说rigidbody.linearVelocity()方法不存在,请问怎么解决?

getComponent(cc.RigidBody)

谢谢啦