Пример #1
0
        private ITagClass TryAddClass(int magic)
        {
            for (int j = 0; j < Classes.Count(); j++)
            {
                if (Classes[j].Magic == magic) // Check of magic already exists
                {
                    return(Classes[j]);        // Exists, return it.

                    break;
                }
            }
            // Does not exist. Create it and return it.
            FourthGenTagClass tagclass = new FourthGenTagClass(magic);

            Classes.Add(tagclass);
            return(tagclass);
        }
Пример #2
0
        private ITagClass TryAddClass(StructureValueCollection values)
        {
            uint magic = values.GetInteger("magic");

            for (int j = 0; j < Classes.Count(); j++)
            {
                if (Classes[j].Magic == magic) // Check of magic already exists
                {
                    return(Classes[j]);        // Exists, return it.

                    break;
                }
            }
            // Does not exist. Create it and return it.
            FourthGenTagClass tagclass = new FourthGenTagClass(values);

            Classes.Add(tagclass);
            return(tagclass);
        }
Пример #3
0
 private ITagClass TryAddClass(int magic)
 {
     for (int j = 0; j < Classes.Count(); j++)
     {
         if (Classes[j].Magic == magic) // Check of magic already exists
         {
             return Classes[j]; // Exists, return it.
             break;
         }
     }
     // Does not exist. Create it and return it.
     FourthGenTagClass tagclass = new FourthGenTagClass(magic);
     Classes.Add(tagclass);
     return tagclass;
 }
Пример #4
0
        private ITagClass TryAddClass(StructureValueCollection values)
        {
            uint magic = values.GetInteger("magic");

            for (int j = 0; j < Classes.Count(); j++)
            {
                if (Classes[j].Magic == magic) // Check of magic already exists
                {
                    return Classes[j]; // Exists, return it.
                    break;
                }
            }
            // Does not exist. Create it and return it.
            FourthGenTagClass tagclass = new FourthGenTagClass(values);
            Classes.Add(tagclass);
            return tagclass;
        }