1 /* 2 XorGramana Copyright 2009 James W. Morris, james@jwm-art.net 3 4 This file is part of XorGramana. 5 6 XorGramana is free software: you can redistribute it and/or modify 7 it under the terms of the GNU General Public License as published by 8 the Free Software Foundation, either version 3 of the License, or 9 (at your option) any later version. 10 11 XorGramana is distributed in the hope that it will be useful, 12 but WITHOUT ANY WARRANTY; without even the implied warranty of 13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 GNU General Public License for more details. 15 16 You should have received a copy of the GNU General Public License 17 along with XorGramana. If not, see <http://www.gnu.org/licenses/>. 18 */ 19 #ifndef _TYPES_H 20 #define _TYPES_H 21 22 /* probably should check before doing this */ 23 typedef unsigned char bool; 24 #define TRUE 1 25 #define FALSE 0 26 27 /* type to be used for storing map data within 28 n*n array */ 29 typedef unsigned char map_t; 30 31 /* type to be used for storing coordinates in map. 32 min 0,max 32 (MAP_W,MAP_H defaults). note: no 33 longer requires signed. */ 34 typedef unsigned char xy_t; 35 36 /* type to be used for counters, ie moves_remaining 37 has max 2000 */ 38 typedef signed int ctr_t; 39 40 /* type to be used for storing the level number, 41 requires signed. */ 42 typedef signed short lvl_t; 43 44 /* type to be used for storing contact types, 45 see actions.h CONTACT */ 46 typedef signed short ct_t; 47 48 /* small unsigned type, miscellaneous */ 49 typedef unsigned char su_t; 50 51 /* small signed type, miscellaneous */ 52 typedef signed char ss_t; 53 54 #endif 55