[LayaAirIDE 2.0]linearVelocity 获取的线速度不正确
给一刚体赋值线速度 获取得到的线速度完全是不正确的
let vectory = new Laya.Vector3(-Math.cos(this.angle) * this.v,0,0);
// this.rigidbody.applyForce(vectory);
this.rigidbody.linearVelocity = vectory;
console.log("施加的线速度:");
console.log(vectory);
console.log("获取得到的线速度:");
console.log(this.rigidbody.linearVelocity);
let vectory = new Laya.Vector3(-Math.cos(this.angle) * this.v,0,0);
// this.rigidbody.applyForce(vectory);
this.rigidbody.linearVelocity = vectory;
console.log("施加的线速度:");
console.log(vectory);
console.log("获取得到的线速度:");
console.log(this.rigidbody.linearVelocity);
没有找到相关结果
已邀请:
要回复问题请先登录
2 个回复
013
赞同来自: 强国国国
Aar0n
赞同来自: