引擎Bug反馈三:_id属性不能序列化显示与cc.PhysicsContact.colliderA提示类型错误

Version:CocosCreator v2.3.3
Language:TypeScript

1.Why the property with the name “_id” cannot be displayed?

const {ccclass, property} = cc._decorator;
@ccclass
export default class Test extends cc.Component {
	
	@property({visible:true})
	private _id:number=0;
	
	@property({visible:true})
	private _index:number=0;
	
	start () {
		
	}
}

2.The following properties are of type “cc.PhysicsCollider”.

cc.PhysicsContact.colliderA
cc.PhysicsContact.colliderB

Is it error in the “creator.d.ts” file?

大~哥~好~

改名别叫 _id :grin:

非常抱歉哈,_id 是组件的一个私有变量,并且在编辑器中也用到了,所以无法序列化显示出来。我们会在 3.0 解决这个问题。

应该是的,我们修改一下