Ejemplo n.º 1
0
        public void SetItems(string items)
        {
            Items.Clear();
            ItemFlags.Clear();

            List <string> tmpList   = new List <string>(items.Trim().Split());
            int           itemCount = tmpList.Count / 2 - 1;

            for (int i = 0; i < itemCount; i++)
            {
                string itemX2 = tmpList[i * 2].Trim();
                if (!itemX2.Equals("-1") && itemX2.Length != 0)
                {
                    string itemFlag = tmpList[i * 2 + 1];
                    Items.Add(int.Parse(itemX2));
                    ItemFlags.Add(ulong.Parse(itemFlag) >> 24);
                }
            }
        }
Ejemplo n.º 2
0
        private void Reset()
        {
            Name       = string.Empty;
            PluralName = string.Empty;

            Attributes    = ResetIntArrays(Attributes);
            Proficiencies = ResetIntArrays(Proficiencies);
            Skills        = ResetIntArrays(Skills);

            Items.Clear();
            ItemFlags.Clear();

            int tmpX = 0;

            UpgradeTroop1 = tmpX;
            UpgradeTroop2 = tmpX;
            FactionID     = tmpX;

            string tmp = "0";

            DialogImage = tmp;
            SceneCode   = tmp;
            Reserved    = tmp;
        }