// 
// File name: Config.h
//
// Discription: Описание класса конфигурации
//
// Programmer: Vladimir P. Stasevich (SV)
//
// History: 
//    Created 30.01.2000 (SV)
//

#ifndef CONFIG_H
#define CONFIG_H

#include "dir.h"
#pragma hdrstop

class TConfig
{
   protected:
      char name[MAXPATH];

      unsigned fxMistake;
      unsigned fzMistake;
      unsigned myMistake;
      
   public:
      TConfig()
      { 
         name[0] = '\0'; 

         fxMistake = 0;
         fzMistake = 0;
         myMistake = 0;
      };
      
      char* GetName()
      { return name; };

      void GetMistakes( unsigned& fx, unsigned& fz, unsigned& my )
      {
         fx = fxMistake;
         fz = fzMistake;
         my = myMistake;
      };

      void SetMistakes( unsigned fx, unsigned fz, unsigned my )
      {
         fxMistake = fx;
         fzMistake = fz;
         myMistake = my;
      };

      int SaveToFile( const char *fileName );
      int LoadFromFile( const char *fileName );
};

extern TConfig config;

#endif

