enigma-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Enigma-cvs] enigma/src levels.hh,1.2,1.3


From: Ralf Westram <address@hidden>
Subject: [Enigma-cvs] enigma/src levels.hh,1.2,1.3
Date: Wed, 22 Oct 2003 21:38:47 +0000

Update of /cvsroot/enigma/enigma/src
In directory subversions:/tmp/cvs-serv4576/src

Modified Files:
        levels.hh 
Log Message:
- removed time from LevelStatus; added parameter for revision
- added revision to LevelInfo



Index: levels.hh
===================================================================
RCS file: /cvsroot/enigma/enigma/src/levels.hh,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** levels.hh   20 Oct 2003 16:21:41 -0000      1.2
--- levels.hh   22 Oct 2003 21:38:44 -0000      1.3
***************
*** 65,82 ****
                    const string &n,
                    const string &a,
!                   GameType gt,
!                   int par_time = DEFAULT_TIME
                    )
              : filename(fn), name(n), author(a), type(gt), best_time(par_time)
!         {}
  
        LevelInfo() {
            best_time = DEFAULT_TIME;
!           type = GAMET_ENIGMA;
        }
      };
  
      struct LevelStatus {
!         LevelStatus(int easy=-1, int hard=-1, int fin=0, std::time_t solv = 
0);
          bool operator != (const LevelStatus& other) const;
  
--- 65,87 ----
                    const string &n,
                    const string &a,
!                   const string &rev,
!                   GameType      gt,
!                   int           par_time = DEFAULT_TIME
                    )
              : filename(fn), name(n), author(a), type(gt), best_time(par_time)
!         {
!             revision = atoi(rev.c_str());
!             if (revision<1) revision = 1;
!         }
  
        LevelInfo() {
            best_time = DEFAULT_TIME;
!           type      = GAMET_ENIGMA;
!             revision  = 0;
        }
      };
  
      struct LevelStatus {
!         LevelStatus(int easy=-1, int hard=-1, int fin=0, int solved_rev = 0);
          bool operator != (const LevelStatus& other) const;
  
***************
*** 84,89 ****
          int  time_easy, time_hard; // Best time in seconds (-1: use level 
default)
          int  finished;          // Level solved? 0 = 
no,1=easy,2=hard,3=easy&hard
!         std::time_t solved_at; // date when level was solved last time
!         int solved_revision;    // Revision #  that was solved
      };
  
--- 89,93 ----
          int  time_easy, time_hard; // Best time in seconds (-1: use level 
default)
          int  finished;          // Level solved? 0 = 
no,1=easy,2=hard,3=easy&hard
!         int  solved_revision;    // Revision #  that was solved
      };
  
***************
*** 102,111 ****
          virtual bool load_level (size_t index) = 0;
  
!         virtual const LevelInfo *get_info (size_t index) = 0;
  
          virtual px::Surface *load_preview (size_t /*index*/) { return 0; }
  
!         //! Return file modification time of level(pack)
!         virtual std::time_t get_modtime(size_t index) = 0;
  
          //! Return the default SoundSet (see options::SoundSet for meaning)
--- 106,115 ----
          virtual bool load_level (size_t index) = 0;
  
!         virtual const LevelInfo *get_info (size_t index) const = 0;
  
          virtual px::Surface *load_preview (size_t /*index*/) { return 0; }
  
!         //! Return revision number of level
!         virtual int get_revision_number(size_t index) const = 0;
  
          //! Return the default SoundSet (see options::SoundSet for meaning)





reply via email to

[Prev in Thread] Current Thread [Next in Thread]