00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef ADIKT_OBJSLABS_H
00021 #define ADIKT_OBJSLABS_H
00022
00023 struct LEVEL;
00024 struct IPOINT_2D;
00025
00026 #include "globals.h"
00027
00028 #define SLAB_TYPE_ROCK 0x00
00029 #define SLAB_TYPE_GOLD 0x01
00030 #define SLAB_TYPE_EARTH 0x02
00031 #define SLAB_TYPE_TORCHDIRT 0x03
00032 #define SLAB_TYPE_WALLDRAPE 0x04
00033 #define SLAB_TYPE_WALLTORCH 0x05
00034 #define SLAB_TYPE_WALLWTWINS 0x06
00035 #define SLAB_TYPE_WALLWWOMAN 0x07
00036 #define SLAB_TYPE_WALLPAIRSHR 0x08
00037 #define SLAB_TYPE_PATH 0x0a
00038 #define SLAB_TYPE_CLAIMED 0x0b
00039 #define SLAB_TYPE_LAVA 0x0c
00040 #define SLAB_TYPE_WATER 0x0d
00041 #define SLAB_TYPE_PORTAL 0x0e
00042 #define SLAB_TYPE_TREASURE 0x10
00043 #define SLAB_TYPE_LIBRARY 0x12
00044 #define SLAB_TYPE_PRISONCASE 0x14
00045 #define SLAB_TYPE_TORTURE 0x16
00046 #define SLAB_TYPE_TRAINING 0x18
00047 #define SLAB_TYPE_DUNGHEART 0x1a
00048 #define SLAB_TYPE_WORKSHOP 0x1c
00049 #define SLAB_TYPE_SCAVENGER 0x1e
00050 #define SLAB_TYPE_TEMPLE 0x20
00051 #define SLAB_TYPE_GRAVEYARD 0x22
00052 #define SLAB_TYPE_HATCHERY 0x24
00053 #define SLAB_TYPE_LAIR 0x26
00054 #define SLAB_TYPE_BARRACKS 0x28
00055 #define SLAB_TYPE_DOORWOOD1 0x2a
00056 #define SLAB_TYPE_DOORWOOD2 0x2b
00057 #define SLAB_TYPE_DOORBRACE1 0x2c
00058 #define SLAB_TYPE_DOORBRACE2 0x2d
00059 #define SLAB_TYPE_DOORIRON1 0x2e
00060 #define SLAB_TYPE_DOORIRON2 0x2f
00061 #define SLAB_TYPE_DOORMAGIC1 0x30
00062 #define SLAB_TYPE_DOORMAGIC2 0x31
00063 #define SLAB_TYPE_BRIDGE 0x33
00064 #define SLAB_TYPE_GEMS 0x34
00065 #define SLAB_TYPE_GUARDPOST 0x35
00066
00067 #define PLAYERS_COUNT 6
00068 #define PLAYER0 0x00
00069 #define PLAYER1 0x01
00070 #define PLAYER2 0x02
00071 #define PLAYER3 0x03
00072 #define PLAYER_GOOD 0x04
00073 #define PLAYER_UNSET 0x05
00074 #define PLAYER_ALL 0x06 //used in scripts only
00075
00076 extern char const SLB_UNKN_LTEXT[];
00077 extern char const SLB_ROCK_LTEXT[];
00078 extern char const SLB_GOLD_LTEXT[];
00079 extern char const SLB_EARTH_LTEXT[];
00080 extern char const SLB_TORCHDIRT_LTEXT[];
00081 extern char const SLB_WALLDRAPE_LTEXT[];
00082 extern char const SLB_WALLTORCH_LTEXT[];
00083 extern char const SLB_WALLWTWINS_LTEXT[];
00084 extern char const SLB_WALLWWOMAN_LTEXT[];
00085 extern char const SLB_WALLPAIRSHR_LTEXT[];
00086 extern char const SLB_PATH_LTEXT[];
00087 extern char const SLB_CLAIMED_LTEXT[];
00088 extern char const SLB_LAVA_LTEXT[];
00089 extern char const SLB_WATER_LTEXT[];
00090 extern char const SLB_PORTAL_LTEXT[];
00091 extern char const SLB_TREASURE_LTEXT[];
00092 extern char const SLB_LIBRARY_LTEXT[];
00093 extern char const SLB_PRISON_LTEXT[];
00094 extern char const SLB_TORTURE_LTEXT[];
00095 extern char const SLB_TRAINING_LTEXT[];
00096 extern char const SLB_DUNGHEART_LTEXT[];
00097 extern char const SLB_WORKSHOP_LTEXT[];
00098 extern char const SLB_SCAVENGER_LTEXT[];
00099 extern char const SLB_TEMPLE_LTEXT[];
00100 extern char const SLB_GRAVEYARD_LTEXT[];
00101 extern char const SLB_HATCHERY_LTEXT[];
00102 extern char const SLB_LAIR_LTEXT[];
00103 extern char const SLB_BARRACKS_LTEXT[];
00104 extern char const SLB_DOORWOOD_LTEXT[];
00105 extern char const SLB_DOORBRACE_LTEXT[];
00106 extern char const SLB_DOORIRON_LTEXT[];
00107 extern char const SLB_DOORMAGIC_LTEXT[];
00108 extern char const SLB_BRIDGE_LTEXT[];
00109 extern char const SLB_GEMS_LTEXT[];
00110 extern char const SLB_GUARDPOST_LTEXT[];
00111
00112 DLLIMPORT short slab_is_central(struct LEVEL *lvl,int x,int y);
00113 DLLIMPORT short slabs_verify(struct LEVEL *lvl, char *err_msg,struct IPOINT_2D *errpt);
00114
00115 DLLIMPORT int slab_siblings_oftype(struct LEVEL *lvl,int x,int y,unsigned short slab_type);
00116 DLLIMPORT void slab_draw_smear(struct LEVEL *lvl,int startx,int starty,int startr,
00117 int endx,int endy,int endr,int bend,unsigned short slab_type);
00118 DLLIMPORT void slab_draw_circle(struct LEVEL *lvl,int x,int y,int rad,unsigned short slab_type);
00119
00120 DLLIMPORT short slab_is_short(unsigned short slab_type);
00121 DLLIMPORT short slab_is_door(unsigned short slab_type);
00122 DLLIMPORT short slab_is_room(unsigned short slab_type);
00123 DLLIMPORT short slab_is_wall(unsigned short slab_type);
00124 DLLIMPORT short slab_is_wealth(unsigned short slab_type);
00125 DLLIMPORT short slab_is_space(unsigned short slab_type);
00126 DLLIMPORT short slab_is_tall_unclmabl(unsigned short slab_type);
00127 DLLIMPORT short slab_is_tall(unsigned short slab_type);
00128 DLLIMPORT short slab_is_short_clmabl(unsigned short slab_type);
00129 DLLIMPORT short slab_is_short_unclmabl(unsigned short slab_type);
00130 DLLIMPORT short slab_is_clmabl(unsigned short slab_type);
00131 DLLIMPORT short slab_is_claimedgnd(unsigned short slab_type);
00132 DLLIMPORT short slab_is_liquid(unsigned short slab_type);
00133 DLLIMPORT short slab_allows_torch(unsigned short slab_type);
00134 DLLIMPORT short slab_needs_adjacent_torch(unsigned short slab_type);
00135 DLLIMPORT short slab_verify_entry(unsigned short slab_type, char *err_msg);
00136 DLLIMPORT char *get_slab_fullname(unsigned short slb_type);
00137 DLLIMPORT unsigned short get_random_wall_slab(void);
00138
00139 DLLIMPORT short subtl_is_near_tall_slab(struct LEVEL *lvl,unsigned int sx,unsigned int sy);
00140
00141 DLLIMPORT short place_room_rndpos(struct LEVEL *lvl,const unsigned short rslab,
00142 const unsigned char rown,const struct IPOINT_2D *rsize);
00143
00144 DLLIMPORT char *get_owner_type_fullname(unsigned char own_idx);
00145 DLLIMPORT char *get_owner_type_colorname(unsigned char own_idx);
00146 DLLIMPORT unsigned char get_owner_next(unsigned char plyr_idx);
00147 DLLIMPORT unsigned char get_owner_prev(unsigned char plyr_idx);
00148 DLLIMPORT void update_slab_owners(struct LEVEL *lvl);
00149
00150 #endif // ADIKT_OBJSLABS_H