Main Page | Modules | Alphabetical List | Data Structures | File List | Data Fields | Globals | Related Pages

include/map.h

Go to the documentation of this file.
00001 // map.h
00004 
00005 #ifndef MAP_H
00006 #define MAP_H
00007 
00008 #ifndef DATA_FILE
00009 //{{{
00010 struct spec_descriptor_ext_level
00011 {
00012     struct filelink destmap;
00013     struct coord destcoord;
00014 };
00015 TYPEDEF(struct spec_descriptor_ext_level spec_descriptor_ext_level)
00016 //}}}
00017 //{{{
00018 union spec_descriptor_ext
00019 {
00020     struct spec_descriptor_ext_level lvl;
00021     struct filelink spec_item;
00022     struct filelink spec_monster;
00023     uint sign_id;
00024 };
00025 TYPEDEF(union spec_descriptor_ext spec_descriptor_ext)
00026 //}}}
00027 //{{{
00028 struct spec_descriptor
00029 {
00030     sint type; // If >=0, this is a tile index; else, corresponds to defs below
00031     struct coord location;
00032     union spec_descriptor_ext ext;
00033 };
00034 TYPEDEF(struct spec_descriptor spec_descriptor)
00035 //}}}
00036 #endif
00037 //{{{
00038 #define MAPSPEC_ITEM    -1
00039 #define MAPSPEC_MONSTER -2
00040 #define MAPSPEC_CONNECT -3
00041 //}}}
00042 
00043 //{{{
00050 struct mapdesc
00051 {
00053     struct filelink name;
00055     struct filelink monstertab;
00057     struct filelink genmethod;
00059     struct filelink genfunction;
00061     struct filelink enterfunction;
00062     
00063     uint mapindex;     
00064     
00068     uint flags;
00069     
00072     uint difficulty;   
00073     
00074     struct range num_items;  
00075     uint initial_population; 
00076     uint numspecial;         
00077 #ifndef DATA_FILE
00078     spec_descriptor ext[1];
00079 #endif
00080 };
00081 TYPEDEF(struct mapdesc mapdesc)
00082 //}}}
00083  //{{{ Map flags
00091 #define MAPFLAG_NORANDMONST 1
00093 #define MAPFLAG_OUTSIDE     4
00094 
00095 #define MAPFLAG_NOMONST     8
00096 
00097 #define MAPFLAG_NOTELEPORT  16
00098 
00099 #define MAPFLAG_EASYDIGGING 32
00100 
00101 //}}}
00102 //{{{
00103 struct map_gen_method
00104 {
00105     ushort size_x;
00106     ushort size_y;
00107     uchar global_light;
00108     uchar padding;
00109     char data[1];
00110 };
00111 TYPEDEF(struct map_gen_method map_gen_method)
00112 //}}}
00113 
00114 //{{{
00115 struct room
00116 {
00117     short left;
00118     short right;
00119     short top;
00120     short bottom;
00121 };
00122 TYPEDEF(struct room room)
00123 //}}}
00124 
00125 #endif //MAP_H
00126 

Generated on Thu May 20 13:12:09 2004 for CalcRogue by doxygen 1.3.6