/// <summary> /// 删除物品,并保存 /// </summary> /// <param name="package"></param> /// <param name="itemId"></param> /// <returns></returns> public MessageCode DeleteItem(ItemPackageFrame package, Guid itemId, int count = 0) { var code = package.Delete(itemId, count, true); if (code == MessageCode.Success) { if (package.Save()) { package.Shadow.Save(); return(code); } else { return(MessageCode.NbUpdateFail); } } return(code); }