2 BobToolz plugin for GtkRadiant
\r
3 Copyright (C) 2001 Gordon Biggans
\r
5 This library is free software; you can redistribute it and/or
\r
6 modify it under the terms of the GNU Lesser General Public
\r
7 License as published by the Free Software Foundation; either
\r
8 version 2.1 of the License, or (at your option) any later version.
\r
10 This library is distributed in the hope that it will be useful,
\r
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
\r
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
\r
13 Lesser General Public License for more details.
\r
15 You should have received a copy of the GNU Lesser General Public
\r
16 License along with this library; if not, write to the Free Software
\r
17 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
\r
20 // DEntity.h: interface for the DEntity class.
\r
22 //////////////////////////////////////////////////////////////////////
\r
24 #if !defined(AFX_DENTITY_H__35B2C523_F0A7_11D4_ACF7_004095A18133__INCLUDED_)
\r
25 #define AFX_DENTITY_H__35B2C523_F0A7_11D4_ACF7_004095A18133__INCLUDED_
\r
30 #include "StdAfx.h" // Added by ClassView
\r
34 #endif // _MSC_VER > 1000
\r
39 void RemoveFromRadiant();
\r
40 entity_t* QER_Entity;
\r
43 // Constrcution/Destruction
\r
44 DEntity(char* classname = "worldspawn", int ID = -1); // sets classname
\r
46 // ---------------------------------------------
\r
48 // epair functions........
\r
49 void LoadEPairList(epair_t* epl);
\r
50 void AddEPair(char* key, char* value);
\r
52 DEPair* FindEPairByKey(const char* keyname);
\r
53 // ---------------------------------------------
\r
55 // random functions........
\r
56 bool ResetTextures(const char* textureName, float fScale[2], float fShift[2], int rotation, const char* newTextureName, int bResetTextureName, int bResetScale[2], int bResetShift[2], int bResetRotation, bool rebuild);
\r
57 void SaveToFile(FILE* pFile);
\r
58 void SetClassname(char* classname);
\r
61 void BuildInRadiant(bool allowDestruction);
\r
62 void ResetChecks(list<Str>* exclusionList);
\r
63 void RemoveNonCheckBrushes(list<Str>* exclusionList, bool useDetail);
\r
65 DPlane* AddFaceToBrush(vec3_t va, vec3_t vb, vec3_t vc, _QERFaceData* faceData, int ID); // slow, try not to use much
\r
66 int GetBrushCount( void );
\r
67 DBrush* FindBrushByPointer( brush_t* brush );
\r
68 // ---------------------------------------------
\r
71 // bool list functions
\r
72 void SelectBrushes(bool* selectList);
\r
73 bool* BuildDuplicateList();
\r
74 bool* BuildIntersectList();
\r
75 // ---------------------------------------------
\r
79 void ClearBrushes(); // clears brush list and frees memory for brushes
\r
81 DBrush* GetBrushForID(int ID);
\r
82 DBrush* NewBrush(int ID = -1);
\r
83 // ---------------------------------------------
\r
86 void ClearPatches();
\r
89 // ---------------------------------------------
\r
92 list<DEPair*> epairList;
\r
93 list<DBrush*> brushList;
\r
94 // new patches, wahey!!!
\r
95 list<DPatch*> patchList;
\r
97 // ---------------------------------------------
\r
100 int FixBrushes(bool rebuild);
\r
102 bool LoadFromEntity(int id, bool bLoadPatches = FALSE);
\r
103 bool LoadFromEntity(entity_t* ent, bool bLoadPatches = FALSE);
\r
104 void LoadSelectedBrushes();
\r
105 void LoadSelectedPatches();
\r
107 bool LoadFromPrt(char* filename);
\r
108 // ---------------------------------------------
\r
109 void SpawnString(const char* key, const char* defaultstring, const char** out);
\r
110 void SpawnInt(const char* key, const char* defaultstring, int* out);
\r
111 void SpawnFloat(const char* key, const char* defaultstring, float* out);
\r
112 void SpawnVector(const char* key, const char* defaultstring, vec_t* out);
\r
115 #endif // !defined(AFX_DENTITY_H__35B2C523_F0A7_11D4_ACF7_004095A18133__INCLUDED_)
\r