1 /* ---------------------------------------------------------------------- *
2  * lintypes.h
3  * This file is part of lincity.
4  * Lincity is copyright (c) I J Peters 1995-1997, (c) Greg Sharp 1997-2001.
5  * ---------------------------------------------------------------------- */
6 #ifndef __lintypes_h__
7 #define __lintypes_h__
8 
9 #ifndef TRUE
10 #define TRUE 1
11 #endif
12 #ifndef FALSE
13 #define FALSE 0
14 #endif
15 
16 #define NUM_OF_TYPES    400
17 #define NUM_OF_GROUPS    42
18 #define GROUP_NAME_LEN   20
19 
20 struct GROUP
21 {
22     char  name[GROUP_NAME_LEN+1];      /* name of group */
23     unsigned short        no_credit;   /* TRUE if need credit to build */
24     unsigned short        group;       /* This is redundant: it must match
25 					  the index into the table */
26     unsigned short        size;
27     int   colour;         /* summary map colour */
28     int   cost_mul;       /* group cost multiplier */
29     int   bul_cost;       /* group bulldoze cost */
30     int   fire_chance;    /* probability of fire */
31     int   cost;           /* group cost */
32     int   tech;           /* group cost */
33 };
34 
35 struct TYPE
36 {
37     int group;          /* What group does this type belong to? */
38     char* graphic;      /* Bitmap of the graphic */
39 };
40 
41 int get_group_of_type (short selected_type);
42 void set_map_groups (void);
43 int get_type_cost (short type);
44 int get_group_cost (short group);
45 void get_type_name (short type, char * s);
46 
47 extern struct GROUP main_groups[NUM_OF_GROUPS];
48 extern struct TYPE main_types[NUM_OF_TYPES];
49 
50 #endif /* __lintypes_h__ */
51