]> de.git.xonotic.org Git - xonotic/netradiant.git/blob - radiant/map.h
transfer from internal tree r5311 branches/1.4-gpl
[xonotic/netradiant.git] / radiant / map.h
1 /*\r
2 Copyright (C) 1999-2007 id Software, Inc. and contributors.\r
3 For a list of contributors, see the accompanying CONTRIBUTORS file.\r
4 \r
5 This file is part of GtkRadiant.\r
6 \r
7 GtkRadiant is free software; you can redistribute it and/or modify\r
8 it under the terms of the GNU General Public License as published by\r
9 the Free Software Foundation; either version 2 of the License, or\r
10 (at your option) any later version.\r
11 \r
12 GtkRadiant is distributed in the hope that it will be useful,\r
13 but WITHOUT ANY WARRANTY; without even the implied warranty of\r
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\r
15 GNU General Public License for more details.\r
16 \r
17 You should have received a copy of the GNU General Public License\r
18 along with GtkRadiant; if not, write to the Free Software\r
19 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA\r
20 */\r
21 \r
22 // map.h -- the state of the current world that all views are displaying\r
23 \r
24 extern  char            currentmap[1024];\r
25 \r
26 // head/tail of doubly linked lists\r
27 extern  brush_t active_brushes; // brushes currently being displayed\r
28 extern  brush_t selected_brushes;       // highlighted\r
29 \r
30 extern CPtrArray& g_ptrSelectedFaces;\r
31 extern CPtrArray& g_ptrSelectedFaceBrushes;\r
32 \r
33 extern  brush_t filtered_brushes;       // brushes that have been filtered or regioned\r
34 \r
35 extern  entity_t        entities;\r
36 extern  entity_t        *world_entity;  // the world entity is NOT included in\r
37                                                                         // the entities chain\r
38 \r
39 extern  int     modified;               // for quit confirmations\r
40 \r
41 extern  vec3_t  region_mins, region_maxs;\r
42 extern  qboolean        region_active;\r
43 \r
44 extern brush_t    *region_sides[6];\r
45 \r
46 void Map_Init();\r
47 \r
48 void    Map_LoadFile (const char *filename);\r
49 void    Map_SaveFile (const char *filename, qboolean use_region);\r
50 \r
51 void    Map_New (void);\r
52 void  Map_Free (void);\r
53 void    Map_BuildBrushData(void);\r
54 \r
55 void    Map_RegionOff (void);\r
56 void    Map_RegionXY (void);\r
57 void    Map_RegionTallBrush (void);\r
58 void    Map_RegionBrush (void);\r
59 void    Map_RegionSelectedBrushes (void);\r
60 qboolean Map_IsBrushFiltered (brush_t *b);\r
61 \r
62 void Map_ImportFile (const char *filename);\r
63 void Map_SaveSelected(const char* filename);\r
64 //void Map_SaveSelected(MemStream* pMemFile, MemStream* pPatchFile = NULL);\r
65 //void Map_ImportBuffer (char* buf);\r
66 \r
67 void  Map_StartPosition(void);\r
68 void Region_SpawnPoint(FILE *f);\r
69 \r
70 void Map_Import(IDataStream *in, const char* type, bool bAddSelected = false);\r
71 void Map_Export(IDataStream *out, const char* type, bool bRegionOnly = false , bool bSelectedOnly = false);\r
72 \r