Virtual U.org
Get Personal Training on VU Today
    
Top shadow
 
 register/help
User Name:

Password:

OPLANT.H Source File
Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members  

OPLANT.H

Go to the documentation of this file.
00001 //Filename    : OPLANT.h
00002 //Description : PlantRes Class Declaration
00003 
00004 #ifndef __OPLANT_H
00005 #define __OPLANT_H
00006 
00007 #ifndef __ORESX_H
00008 #include <ORESX.H>
00009 #endif
00010 
00011 //------- Define PlantRec --------//
00012 
00015 struct PlantRec {
00016     enum { FILE_NAME_LEN=8 };
00017 
00018     char  file_name[FILE_NAME_LEN];
00019 };
00020 
00021 //------ Define struct PlantInfo --------//
00022 
00025 struct PlantInfo {
00026     enum { FILE_NAME_LEN=8 };
00027 
00028     char  file_name[FILE_NAME_LEN+1];
00029     char* bitmap_ptr[MAX_ZOOM_LEVEL];
00030 };
00031 
00032 //------- Define class PlantRes ---------//
00033 
00036 class PlantRes {
00037 public:
00038     bool      init_flag;
00039 
00040     short     plant_count;
00041     PlantInfo*  info_array;
00042 
00043     ResourceIdx res_bitmap[MAX_ZOOM_LEVEL];
00044 
00045 public:
00046     PlantRes();
00047     ~PlantRes();                                  // public for compilation error if private
00048 
00049     void        init();
00050     void        deinit();
00051 
00052     PlantInfo*    operator[](int plantId);
00053 
00054 private:
00055     void        load_info();
00056     void        load_bmp_info(char* fileName);
00057 
00058     void        load_res(int bmpSizeType, char* namePrefix, char* nameSuffix);
00059 };
00060 
00061 extern PlantRes plant_res;
00062 
00063 //-----------------------------------------------//
00064 #endif

Generated on Fri Aug 23 01:38:11 2002 for VirtualU by doxygen1.2.17