Creator后续计划什么时候能让编辑器支持 键值对 这样的类型呢?

目前版本2.0.5

@property({ type: [String], displayName: “参数” })
params: Array = [];

希望能增加
@property({ type: [{k:string,v:string}], displayName: “参数” })
params: Array<{k:string,v:string}> = [];

这个可以用 ccclass 实现:

@ccclass("XXXAttr")
export class XXXAttr {
    @property(cc.ProgressBar)
    public eBar: cc.ProgressBar = null;
    @property(cc.Label)
    public eLaber: cc.Label = null;
}

@ccclass
export default class XXX extends cc.Component {
    @property(XXXAttr)
    public eHp: XXXAttr = null;
    @property(XXXAttr)
    public eMana: XXXAttr = null;
}
2赞

绕一下,但是挺好的解决了,厉害