示例#1
0
        public Transition(string iDescription, ClsTerrain iGroupA, ClsTerrain iGroupB, string iHashKey, MapTile iMapTile)
        {
            this.m_HashKey     = new HashKeyCollection();
            this.m_StaticTiles = new StaticTileCollection();
            this.m_MapTiles    = new MapTileCollection();
            this.m_RandomTiles = null;
            this.m_File        = null;
            this.m_Description = iDescription;
            byte b = 0;

            do
            {
                string sLeft = Strings.Mid(iHashKey, (int)checked (b + 1), 1);
                if (StringType.StrCmp(sLeft, "A", false) == 0)
                {
                    this.m_HashKey.Add(new HashKey(iGroupA.GroupID));
                }
                else
                {
                    if (StringType.StrCmp(sLeft, "B", false) == 0)
                    {
                        this.m_HashKey.Add(new HashKey(iGroupB.GroupID));
                    }
                }
                b += 1;
            }while (b <= 8);
            this.m_MapTiles.Add(iMapTile);
        }
示例#2
0
        public Transition(string iDescription, ClsTerrain iGroupA, ClsTerrain iGroupB, ClsTerrain iGroupC, string iHashKey)
        {
            this.m_HashKey     = new HashKeyCollection();
            this.m_StaticTiles = new StaticTileCollection();
            this.m_MapTiles    = new MapTileCollection();
            this.m_RandomTiles = (RandomStatics)null;
            this.m_File        = (string)null;
            this.m_Description = iDescription;
            byte num = (byte)0;

            do
            {
                string sLeft = Strings.Mid(iHashKey, checked ((int)num + 1), 1);
                if (StringType.StrCmp(sLeft, "A", false) == 0)
                {
                    this.m_HashKey.Add(new HashKey(iGroupA.GroupID));
                }
                else if (StringType.StrCmp(sLeft, "B", false) == 0)
                {
                    this.m_HashKey.Add(new HashKey(iGroupB.GroupID));
                }
                else if (StringType.StrCmp(sLeft, "C", false) == 0)
                {
                    this.m_HashKey.Add(new HashKey(iGroupC.GroupID));
                }
                ++num;
            }while ((int)num <= 8);
        }
        public Transition(string iDescription, ClsTerrain iGroupA, ClsTerrain iGroupB, string iHashKey, MapTile iMapTile)
        {
            this.m_HashKey     = new HashKeyCollection();
            this.m_StaticTiles = new StaticTileCollection();
            this.m_MapTiles    = new MapTileCollection();
            this.m_RandomTiles = null;
            this.m_File        = null;
            this.m_Description = iDescription;
            byte num = 0;

            do
            {
                string str = Strings.Mid(iHashKey, checked (num + 1), 1);
                if (StringType.StrCmp(str, "A", false) == 0)
                {
                    this.m_HashKey.Add(new Transition.HashKey(iGroupA.GroupID));
                }
                else if (StringType.StrCmp(str, "B", false) == 0)
                {
                    this.m_HashKey.Add(new Transition.HashKey(iGroupB.GroupID));
                }
                num = checked ((byte)(num + 1));
            }while (num <= 8);
            this.m_MapTiles.Add(iMapTile);
        }
示例#4
0
        public Transition(string iDescription, string iHashKey)
        {
            this.m_HashKey     = new HashKeyCollection();
            this.m_StaticTiles = new StaticTileCollection();
            this.m_MapTiles    = new MapTileCollection();
            this.m_RandomTiles = (RandomStatics)null;
            this.m_File        = (string)null;
            this.m_Description = iDescription;
            byte num = (byte)0;

            do
            {
                this.m_HashKey.Add(new HashKey(Strings.Mid(iHashKey, checked ((int)num * 2 + 1), 2)));
                ++num;
            }while ((int)num <= 8);
        }
        public Transition(string iDescription, string iHashKey)
        {
            this.m_HashKey     = new HashKeyCollection();
            this.m_StaticTiles = new StaticTileCollection();
            this.m_MapTiles    = new MapTileCollection();
            this.m_RandomTiles = null;
            this.m_File        = null;
            this.m_Description = iDescription;
            byte num = 0;

            do
            {
                this.m_HashKey.Add(new Transition.HashKey(Strings.Mid(iHashKey, checked (checked (num * 2) + 1), 2)));
                num = checked ((byte)(num + 1));
            }while (num <= 8);
        }
示例#6
0
        public Transition(string iDescription, string iHashKey)
        {
            this.m_HashKey     = new HashKeyCollection();
            this.m_StaticTiles = new StaticTileCollection();
            this.m_MapTiles    = new MapTileCollection();
            this.m_RandomTiles = null;
            this.m_File        = null;
            this.m_Description = iDescription;
            byte b = 0;

            do
            {
                this.m_HashKey.Add(new HashKey(Strings.Mid(iHashKey, (int)checked (b * 2 + 1), 2)));
                b += 1;
            }while (b <= 8);
        }
示例#7
0
        public Transition()
        {
            this.m_HashKey     = new HashKeyCollection();
            this.m_StaticTiles = new StaticTileCollection();
            this.m_MapTiles    = new MapTileCollection();
            this.m_RandomTiles = null;
            this.m_File        = null;
            this.m_Description = "<New Transition>";
            this.m_HashKey.Clear();
            byte b = 0;

            do
            {
                this.m_HashKey.Add(new HashKey());
                b += 1;
            }while (b <= 8);
        }
 public Transition(XmlElement xmlInfo)
 {
     this.m_HashKey     = new HashKeyCollection();
     this.m_StaticTiles = new StaticTileCollection();
     this.m_MapTiles    = new MapTileCollection();
     this.m_RandomTiles = null;
     this.m_File        = null;
     this.m_Description = xmlInfo.GetAttribute("Description");
     this.m_HashKey.AddHashKey(xmlInfo.GetAttribute("HashKey"));
     if (StringType.StrCmp(xmlInfo.GetAttribute("File"), string.Empty, false) != 0)
     {
         this.m_RandomTiles = new RandomStatics(xmlInfo.GetAttribute("File"));
         this.m_File        = xmlInfo.GetAttribute("File");
     }
     this.m_MapTiles.Load(xmlInfo);
     this.m_StaticTiles.Load(xmlInfo);
 }
示例#9
0
        public Transition()
        {
            this.m_HashKey     = new HashKeyCollection();
            this.m_StaticTiles = new StaticTileCollection();
            this.m_MapTiles    = new MapTileCollection();
            this.m_RandomTiles = (RandomStatics)null;
            this.m_File        = (string)null;
            this.m_Description = "<New Transition>";
            this.m_HashKey.Clear();
            byte num = (byte)0;

            do
            {
                this.m_HashKey.Add(new HashKey());
                ++num;
            }while ((int)num <= 8);
        }
        public Transition()
        {
            this.m_HashKey     = new HashKeyCollection();
            this.m_StaticTiles = new StaticTileCollection();
            this.m_MapTiles    = new MapTileCollection();
            this.m_RandomTiles = null;
            this.m_File        = null;
            this.m_Description = "<New Transition>";
            this.m_HashKey.Clear();
            byte num = 0;

            do
            {
                this.m_HashKey.Add(new Transition.HashKey());
                num = checked ((byte)(num + 1));
            }while (num <= 8);
        }
示例#11
0
        public Transition(string iDescription, string iHashKey, MapTileCollection iMapTiles, StaticTileCollection iStaticTiles)
        {
            this.m_HashKey     = new HashKeyCollection();
            this.m_StaticTiles = new StaticTileCollection();
            this.m_MapTiles    = new MapTileCollection();
            this.m_RandomTiles = null;
            this.m_File        = null;
            this.m_Description = iDescription;
            this.m_HashKey.AddHashKey(iHashKey);

            IEnumerator enumerator = iMapTiles.GetEnumerator();

            try
            {
                while (enumerator.MoveNext())
                {
                    MapTile value = (MapTile)enumerator.Current;
                    this.m_MapTiles.Add(value);
                }
            }
            finally
            {
                if (enumerator is IDisposable)
                {
                    ((IDisposable)enumerator).Dispose();
                }
            }

            IEnumerator enumerator2 = iStaticTiles.GetEnumerator();

            try
            {
                while (enumerator2.MoveNext())
                {
                    StaticTile value2 = (StaticTile)enumerator2.Current;
                    this.m_StaticTiles.Add(value2);
                }
            }
            finally
            {
                if (enumerator2 is IDisposable)
                {
                    ((IDisposable)enumerator2).Dispose();
                }
            }
        }
        public Transition(string iDescription, string iHashKey, MapTileCollection iMapTiles, StaticTileCollection iStaticTiles)
        {
            this.m_HashKey = new HashKeyCollection();
            this.m_StaticTiles = new StaticTileCollection();
            this.m_MapTiles = new MapTileCollection();
            this.m_RandomTiles = null;
            this.m_File = null;
            this.m_Description = iDescription;
            this.m_HashKey.AddHashKey(iHashKey);

            IEnumerator enumerator = iMapTiles.GetEnumerator();

            try
            {
                while (enumerator.MoveNext())
                {
                    MapTile value = (MapTile)enumerator.Current;
                    this.m_MapTiles.Add(value);
                }
            }
            finally
            {
                if (enumerator is IDisposable)
                {
                    ((IDisposable)enumerator).Dispose();
                }
            }

            IEnumerator enumerator2 = iStaticTiles.GetEnumerator();

            try
            {
                while (enumerator2.MoveNext())
                {
                    StaticTile value2 = (StaticTile)enumerator2.Current;
                    this.m_StaticTiles.Add(value2);
                }
            }
            finally
            {
                if (enumerator2 is IDisposable)
                {
                    ((IDisposable)enumerator2).Dispose();
                }
            }
        }
 public Transition()
 {
     this.m_HashKey = new HashKeyCollection();
     this.m_StaticTiles = new StaticTileCollection();
     this.m_MapTiles = new MapTileCollection();
     this.m_RandomTiles = null;
     this.m_File = null;
     this.m_Description = "<New Transition>";
     this.m_HashKey.Clear();
     byte b = 0;
     do
     {
         this.m_HashKey.Add(new HashKey());
         b += 1;
     }
     while (b <= 8);
 }
 public Transition(XmlElement xmlInfo)
 {
     this.m_HashKey = new HashKeyCollection();
     this.m_StaticTiles = new StaticTileCollection();
     this.m_MapTiles = new MapTileCollection();
     this.m_RandomTiles = null;
     this.m_File = null;
     this.m_Description = xmlInfo.GetAttribute("Description");
     this.m_HashKey.AddHashKey(xmlInfo.GetAttribute("HashKey"));
     if (StringType.StrCmp(xmlInfo.GetAttribute("File"), string.Empty, false) != 0)
     {
         this.m_RandomTiles = new RandomStatics(xmlInfo.GetAttribute("File"));
         this.m_File = xmlInfo.GetAttribute("File");
     }
     this.m_MapTiles.Load(xmlInfo);
     this.m_StaticTiles.Load(xmlInfo);
 }
        public Transition(string iDescription, string iHashKey, MapTileCollection iMapTiles, StaticTileCollection iStaticTiles)
        {
            IEnumerator enumerator  = null;
            IEnumerator enumerator1 = null;

            this.m_HashKey     = new HashKeyCollection();
            this.m_StaticTiles = new StaticTileCollection();
            this.m_MapTiles    = new MapTileCollection();
            this.m_RandomTiles = null;
            this.m_File        = null;
            this.m_Description = iDescription;
            this.m_HashKey.AddHashKey(iHashKey);
            try
            {
                enumerator1 = iMapTiles.GetEnumerator();
                while (enumerator1.MoveNext())
                {
                    MapTile current = (MapTile)enumerator1.Current;
                    this.m_MapTiles.Add(current);
                }
            }
            finally
            {
                if (enumerator1 is IDisposable)
                {
                    ((IDisposable)enumerator1).Dispose();
                }
            }
            try
            {
                enumerator = iStaticTiles.GetEnumerator();
                while (enumerator.MoveNext())
                {
                    Transition.StaticTile staticTile = (Transition.StaticTile)enumerator.Current;
                    this.m_StaticTiles.Add(staticTile);
                }
            }
            finally
            {
                if (enumerator is IDisposable)
                {
                    ((IDisposable)enumerator).Dispose();
                }
            }
        }
示例#16
0
 public Transition(string iDescription, string iHashKey, MapTileCollection iMapTiles, StaticTileCollection iStaticTiles)
 {
     this.m_HashKey     = new HashKeyCollection();
     this.m_StaticTiles = new StaticTileCollection();
     this.m_MapTiles    = new MapTileCollection();
     this.m_RandomTiles = (RandomStatics)null;
     this.m_File        = (string)null;
     this.m_Description = iDescription;
     this.m_HashKey.AddHashKey(iHashKey);
     try
     {
         foreach (MapTile mapTile in (CollectionBase)iMapTiles)
         {
             this.m_MapTiles.Add(mapTile);
         }
     }
     finally
     {
         IEnumerator enumerator;
         if (enumerator is IDisposable)
         {
             ((IDisposable)enumerator).Dispose();
         }
     }
     try
     {
         foreach (StaticTile staticTile in (CollectionBase)iStaticTiles)
         {
             this.m_StaticTiles.Add(staticTile);
         }
     }
     finally
     {
         IEnumerator enumerator;
         if (enumerator is IDisposable)
         {
             ((IDisposable)enumerator).Dispose();
         }
     }
 }
示例#17
0
        public Transition(string iDescription, string iHashKey, ClsTerrain iGroupA, ClsTerrain iGroupB, MapTileCollection iMapTiles, StaticTileCollection iStaticTiles)
        {
            this.m_HashKey     = new HashKeyCollection();
            this.m_StaticTiles = new StaticTileCollection();
            this.m_MapTiles    = new MapTileCollection();
            this.m_RandomTiles = (RandomStatics)null;
            this.m_File        = (string)null;
            this.m_Description = iDescription;
            byte num = (byte)0;

            do
            {
                string sLeft = Strings.Mid(iHashKey, checked ((int)num + 1), 1);
                if (StringType.StrCmp(sLeft, "A", false) == 0)
                {
                    this.m_HashKey.Add(new HashKey(iGroupA.GroupID));
                }
                else if (StringType.StrCmp(sLeft, "B", false) == 0)
                {
                    this.m_HashKey.Add(new HashKey(iGroupB.GroupID));
                }
                ++num;
            }while ((int)num <= 8);
            if (iMapTiles != null)
            {
                try
                {
                    foreach (MapTile mapTile in (CollectionBase)iMapTiles)
                    {
                        this.m_MapTiles.Add(mapTile);
                    }
                }
                finally
                {
                    IEnumerator enumerator;
                    if (enumerator is IDisposable)
                    {
                        ((IDisposable)enumerator).Dispose();
                    }
                }
            }
            if (iStaticTiles == null)
            {
                return;
            }
            try
            {
                foreach (StaticTile staticTile in (CollectionBase)iStaticTiles)
                {
                    this.m_StaticTiles.Add(staticTile);
                }
            }
            finally
            {
                IEnumerator enumerator;
                if (enumerator is IDisposable)
                {
                    ((IDisposable)enumerator).Dispose();
                }
            }
        }
        public Transition(string iDescription, string iHashKey, ClsTerrain iGroupA, ClsTerrain iGroupB, MapTileCollection iMapTiles, StaticTileCollection iStaticTiles)
        {
            IEnumerator enumerator  = null;
            IEnumerator enumerator1 = null;

            this.m_HashKey     = new HashKeyCollection();
            this.m_StaticTiles = new StaticTileCollection();
            this.m_MapTiles    = new MapTileCollection();
            this.m_RandomTiles = null;
            this.m_File        = null;
            this.m_Description = iDescription;
            byte num = 0;

            do
            {
                string str = Strings.Mid(iHashKey, checked (num + 1), 1);
                if (StringType.StrCmp(str, "A", false) == 0)
                {
                    this.m_HashKey.Add(new Transition.HashKey(iGroupA.GroupID));
                }
                else if (StringType.StrCmp(str, "B", false) == 0)
                {
                    this.m_HashKey.Add(new Transition.HashKey(iGroupB.GroupID));
                }
                num = checked ((byte)(num + 1));
            }while (num <= 8);
            if (iMapTiles != null)
            {
                try
                {
                    enumerator1 = iMapTiles.GetEnumerator();
                    while (enumerator1.MoveNext())
                    {
                        MapTile current = (MapTile)enumerator1.Current;
                        this.m_MapTiles.Add(current);
                    }
                }
                finally
                {
                    if (enumerator1 is IDisposable)
                    {
                        ((IDisposable)enumerator1).Dispose();
                    }
                }
            }
            if (iStaticTiles != null)
            {
                try
                {
                    enumerator = iStaticTiles.GetEnumerator();
                    while (enumerator.MoveNext())
                    {
                        Transition.StaticTile staticTile = (Transition.StaticTile)enumerator.Current;
                        this.m_StaticTiles.Add(staticTile);
                    }
                }
                finally
                {
                    if (enumerator is IDisposable)
                    {
                        ((IDisposable)enumerator).Dispose();
                    }
                }
            }
        }
        public Transition(string iDescription, string iHashKey, ClsTerrain iGroupA, ClsTerrain iGroupB, MapTileCollection iMapTiles, StaticTileCollection iStaticTiles)
        {
            this.m_HashKey = new HashKeyCollection();
            this.m_StaticTiles = new StaticTileCollection();
            this.m_MapTiles = new MapTileCollection();
            this.m_RandomTiles = null;
            this.m_File = null;
            this.m_Description = iDescription;
            byte b = 0;
            do
            {
                string sLeft = Strings.Mid(iHashKey, (int)checked(b + 1), 1);
                if (StringType.StrCmp(sLeft, "A", false) == 0)
                {
                    this.m_HashKey.Add(new HashKey(iGroupA.GroupID));
                }
                else
                {
                    if (StringType.StrCmp(sLeft, "B", false) == 0)
                    {
                        this.m_HashKey.Add(new HashKey(iGroupB.GroupID));
                    }
                }
                b += 1;
            }
            while (b <= 8);
            if (iMapTiles != null)
            {
                IEnumerator enumerator = iMapTiles.GetEnumerator();
                try
                {
                    while (enumerator.MoveNext())
                    {
                        MapTile value = (MapTile)enumerator.Current;
                        this.m_MapTiles.Add(value);
                    }
                }
                finally
                {
                    if (enumerator is IDisposable)
                    {
                        ((IDisposable)enumerator).Dispose();
                    }
                }
            }
            if (iStaticTiles != null)
            {
                IEnumerator enumerator2 = iStaticTiles.GetEnumerator();

                try
                {
                    while (enumerator2.MoveNext())
                    {
                        StaticTile value2 = (StaticTile)enumerator2.Current;
                        this.m_StaticTiles.Add(value2);
                    }
                }
                finally
                {
                    if (enumerator2 is IDisposable)
                    {
                        ((IDisposable)enumerator2).Dispose();
                    }
                }
            }
        }
 public Transition(string iDescription, string iHashKey)
 {
     this.m_HashKey = new HashKeyCollection();
     this.m_StaticTiles = new StaticTileCollection();
     this.m_MapTiles = new MapTileCollection();
     this.m_RandomTiles = null;
     this.m_File = null;
     this.m_Description = iDescription;
     byte b = 0;
     do
     {
         this.m_HashKey.Add(new HashKey(Strings.Mid(iHashKey, (int)checked(b * 2 + 1), 2)));
         b += 1;
     }
     while (b <= 8);
 }
示例#21
0
        public Transition(string iDescription, string iHashKey, ClsTerrain iGroupA, ClsTerrain iGroupB, MapTileCollection iMapTiles, StaticTileCollection iStaticTiles)
        {
            this.m_HashKey     = new HashKeyCollection();
            this.m_StaticTiles = new StaticTileCollection();
            this.m_MapTiles    = new MapTileCollection();
            this.m_RandomTiles = null;
            this.m_File        = null;
            this.m_Description = iDescription;
            byte b = 0;

            do
            {
                string sLeft = Strings.Mid(iHashKey, (int)checked (b + 1), 1);
                if (StringType.StrCmp(sLeft, "A", false) == 0)
                {
                    this.m_HashKey.Add(new HashKey(iGroupA.GroupID));
                }
                else
                {
                    if (StringType.StrCmp(sLeft, "B", false) == 0)
                    {
                        this.m_HashKey.Add(new HashKey(iGroupB.GroupID));
                    }
                }
                b += 1;
            }while (b <= 8);
            if (iMapTiles != null)
            {
                IEnumerator enumerator = iMapTiles.GetEnumerator();
                try
                {
                    while (enumerator.MoveNext())
                    {
                        MapTile value = (MapTile)enumerator.Current;
                        this.m_MapTiles.Add(value);
                    }
                }
                finally
                {
                    if (enumerator is IDisposable)
                    {
                        ((IDisposable)enumerator).Dispose();
                    }
                }
            }
            if (iStaticTiles != null)
            {
                IEnumerator enumerator2 = iStaticTiles.GetEnumerator();

                try
                {
                    while (enumerator2.MoveNext())
                    {
                        StaticTile value2 = (StaticTile)enumerator2.Current;
                        this.m_StaticTiles.Add(value2);
                    }
                }
                finally
                {
                    if (enumerator2 is IDisposable)
                    {
                        ((IDisposable)enumerator2).Dispose();
                    }
                }
            }
        }
 public Transition(string iDescription, ClsTerrain iGroupA, ClsTerrain iGroupB, string iHashKey, MapTile iMapTile)
 {
     this.m_HashKey = new HashKeyCollection();
     this.m_StaticTiles = new StaticTileCollection();
     this.m_MapTiles = new MapTileCollection();
     this.m_RandomTiles = null;
     this.m_File = null;
     this.m_Description = iDescription;
     byte b = 0;
     do
     {
         string sLeft = Strings.Mid(iHashKey, (int)checked(b + 1), 1);
         if (StringType.StrCmp(sLeft, "A", false) == 0)
         {
             this.m_HashKey.Add(new HashKey(iGroupA.GroupID));
         }
         else
         {
             if (StringType.StrCmp(sLeft, "B", false) == 0)
             {
                 this.m_HashKey.Add(new HashKey(iGroupB.GroupID));
             }
         }
         b += 1;
     }
     while (b <= 8);
     this.m_MapTiles.Add(iMapTile);
 }