Beispiel #1
0
 public LayerComparer(LayerComparerType comparerType)
 {
     this.m_ComparerType = comparerType;
     Layer[] destinationArray = new Layer[m_DesiredLayerOrder.Length + 3];
     destinationArray[0] = Layer.Mount;
     if (comparerType == LayerComparerType.Forward)
     {
         destinationArray[1] = Layer.Cloak;
         Array.Copy(m_DesiredLayerOrder, 0, destinationArray, 2, m_DesiredLayerOrder.Length);
     }
     else
     {
         Array.Copy(m_DesiredLayerOrder, 0, destinationArray, 1, m_DesiredLayerOrder.Length);
         destinationArray[1 + m_DesiredLayerOrder.Length] = Layer.Cloak;
     }
     destinationArray[destinationArray.Length - 1] = Layer.Backpack;
     this.m_TranslationTable = new int[0x100];
     for (int i = 0; i < destinationArray.Length; i++)
     {
         this.m_TranslationTable[(int) destinationArray[i]] = destinationArray.Length - i;
     }
 }
Beispiel #2
0
 public LayerComparer(LayerComparerType comparerType)
 {
     this.m_ComparerType = comparerType;
     Layer[] destinationArray = new Layer[m_DesiredLayerOrder.Length + 3];
     destinationArray[0] = Layer.Mount;
     if (comparerType == LayerComparerType.Forward)
     {
         destinationArray[1] = Layer.Cloak;
         Array.Copy(m_DesiredLayerOrder, 0, destinationArray, 2, m_DesiredLayerOrder.Length);
     }
     else
     {
         Array.Copy(m_DesiredLayerOrder, 0, destinationArray, 1, m_DesiredLayerOrder.Length);
         destinationArray[1 + m_DesiredLayerOrder.Length] = Layer.Cloak;
     }
     destinationArray[destinationArray.Length - 1] = Layer.Backpack;
     this.m_TranslationTable = new int[0x100];
     for (int i = 0; i < destinationArray.Length; i++)
     {
         this.m_TranslationTable[(int)destinationArray[i]] = destinationArray.Length - i;
     }
 }