internal Enumerator(SortedLimitedList <TKey, TValue> sortedList, int getEnumeratorRetType)
 {
     _sortedList           = sortedList;
     _index                = 0;
     _version              = _sortedList.version;
     _getEnumeratorRetType = getEnumeratorRetType;
     _key   = default;
     _value = default;
 }
Ejemplo n.º 2
0
 /// <summary>
 /// The constructor of the grid spatial partition algorithm
 /// </summary>
 /// <param name="maxX">The max x value</param>
 /// <param name="maxY">The max y value</param>
 /// <param name="areaSize">The Size of a grid area</param>
 /// <param name="xOffset"></param>
 /// <param name="yOffset"></param>
 /// <param name="limit"></param>
 /// <param name="distance"></param>
 public LimitedGrid(int maxX, int maxY, int areaSize, int xOffset, int yOffset, int limit, int distance = 0) : base(maxX,
                                                                                                                    maxY, areaSize, xOffset, yOffset, distance)
 {
     sortedList = new SortedLimitedList <float, IEntity>(limit, limit, _duplicateKeyComparer);
 }
Ejemplo n.º 3
0
 /// <summary>
 /// The constructor of the grid spatial partition algorithm
 /// </summary>
 /// <param name="maxX">The max x value</param>
 /// <param name="maxY">The max y value</param>
 /// <param name="areaSize">The Size of a grid area</param>
 /// <param name="xOffset"></param>
 /// <param name="yOffset"></param>
 /// <param name="limit"></param>
 /// <param name="distance"></param>
 public LimitedPriorityGrid3(int maxX, int maxY, int areaSize, int xOffset, int yOffset, int limit) : base(maxX,
                                                                                                           maxY, areaSize, xOffset, yOffset)
 {
     sortedList = new SortedLimitedList <float, IEntity>(limit, limit, _duplicateKeyComparer);
 }
 internal SortedListKeyEnumerator(SortedLimitedList <TKey, TValue> sortedList)
 {
     _sortedList = sortedList;
     _version    = sortedList.version;
 }
            private SortedLimitedList <TKey, TValue> _dict; // Do not rename (binary serialization)

            internal ValueList(SortedLimitedList <TKey, TValue> dictionary)
            {
                _dict = dictionary;
            }