/// <summary> /// 是否数据一致 /// </summary> protected override bool toDataEquals(BaseData data) { if (!base.toDataEquals(data)) { return(false); } PetSaveData mData = (PetSaveData)data; if (this.level != mData.level) { return(false); } if (this.exp != mData.exp) { return(false); } if (this.isWorking != mData.isWorking) { return(false); } return(true); }
/// <summary> /// 复制(潜拷贝) /// </summary> protected override void toShadowCopy(BaseData data) { base.toShadowCopy(data); if (!(data is PetSaveData)) { return; } PetSaveData mData = (PetSaveData)data; this.level = mData.level; this.exp = mData.exp; this.isWorking = mData.isWorking; }