public static ReplaceEquipmentInfo GetReplaceEquipmentInfo(this EquipmentCollectData equipmentCollectData) { if (equipmentCollectData != null) { EquipmentConfigId equipmentConfigId = equipmentCollectData.EquipmentConfigId; return(new ReplaceEquipmentInfo(equipmentConfigId.VisualId, equipmentConfigId.Rarity)); } return(new ReplaceEquipmentInfo()); }
public static ReplaceEquipmentInfo GetReplaceEquipmentInfo(this MainCharacterData mainCharacterData, EquipmentType equipmentType) { EquipmentCollectData equipmentCollectData = mainCharacterData.InventoryData.GetEquipment(mainCharacterData .PresetData(Preset.Pve).GetEquippedEquipmentCollectId(equipmentType).ToEquipmentCollectId()); if (equipmentCollectData != null) { EquipmentConfigId equipmentConfigId = equipmentCollectData.EquipmentConfigId; return(new ReplaceEquipmentInfo(equipmentConfigId.VisualId, equipmentConfigId.Rarity)); } return(new ReplaceEquipmentInfo()); }