CEngineSharp_Editor.NpcEditor.SaveNpcs C# (CSharp) Method

SaveNpcs() private method

private SaveNpcs ( ) : void
return void
        private void SaveNpcs()
        {
            DirectoryInfo dI = new DirectoryInfo(this.dataPath + "/Npcs/");

            // Delete all of the old files (they will be replaced). We must do this to insure that we don't keep any renamed items.
            foreach (var file in dI.GetFiles("*.dat", SearchOption.TopDirectoryOnly))
                file.Delete();

            foreach (var npc in this.npcs)
            {
                npc.Save(this.dataPath);
            }
        }