Esempio n. 1
0
        public static int SortWithList(SortableEquipment a, SortableEquipment b, List <EquipmentSortMethod> sortingPriority)
        {
            Dictionary <EquipmentSortMethod, ArmorySortUtils.SortEquipmentDelegate> dictionary = ArmorySortUtils.CreateSortDictionary();
            int i     = 0;
            int count = sortingPriority.Count;

            while (i < count)
            {
                ArmorySortUtils.SortEquipmentDelegate sortEquipmentDelegate = dictionary[sortingPriority[i]];
                int num = sortEquipmentDelegate(a, b);
                if (num != 0)
                {
                    return(num);
                }
                i++;
            }
            return(0);
        }
Esempio n. 2
0
 public unsafe static long $Invoke0(long instance, long *args)
 {
     return(GCHandledObjects.ObjectToGCHandle(ArmorySortUtils.CreateSortDictionary()));
 }