Ejemplo n.º 1
0
        static void Main(string[] args)
        {
            bool fin = true;

            ClassLibrary2.FileHandle fileHandle = new FileHandle();


            List <AEffect> AllEffects = fileHandle.LoadDataEfect();
            List <Item>    AllItems   = fileHandle.LoadDataItem();



            string input;

            Console.WriteLine("items t/f");
            input = Console.ReadLine();



            while (fin)
            {
                if (input.Equals("t"))
                {
                    PrintItems(AllItems);
                    Console.ReadLine();
                    AllItems.Add(Additem());
                    fileHandle.SaveData(AllItems);
                }
                else
                {
                    PrintEffects(AllEffects);

                    Console.ReadLine();
                    AllEffects.Add(AddEffect());
                    fileHandle.SaveData(AllEffects);
                }
            }
        }