Esempio n. 1
0
        //Melee properties


        public new static void Initialize()
        {
            FilePath = "Content\\entities\\weapon\\weapons.json";
            try
            {
                string RawFile = File.ReadAllText(FilePath);
                ExistingWeapons = JsonConvert.DeserializeObject <List <Weapon> >(RawFile);

                ExistingItems.AddRange(ExistingWeapons);
            }
            catch (FileNotFoundException e)
            {
                Console.WriteLine(e);
                ExistingWeapons = new List <Weapon>();
            }
        }