using System.Collections; using System.Collections.Generic; using UnityEngine; public partial class LegendPropertyValueConfig : IConfigPostProcess { static Dictionary previewConfigs = new Dictionary(); public void OnConfigParseCompleted() { var key = ItemType * 1000000 + ItemClassLV * 10000 + ItemColor * 100 + IsSuit; previewConfigs[key] = this; } public static LegendPropertyValueConfig Get(int itemType, int level, int quality, bool suit) { var key = itemType * 1000000 + level * 10000 + quality * 100 + (suit ? 1 : 0); return previewConfigs.ContainsKey(key) ? previewConfigs[key] : null; } }