diff options
| author | FluorescentCIAAfricanAmerican <[email protected]> | 2020-04-22 12:56:21 -0400 |
|---|---|---|
| committer | FluorescentCIAAfricanAmerican <[email protected]> | 2020-04-22 12:56:21 -0400 |
| commit | 3bf9df6b2785fa6d951086978a3e66f49427166a (patch) | |
| tree | 2c0f1f0c63c4832882bc93814ebd2c2b1c6224e5 /hammer/mapquadbounds.h | |
| download | archived-source-engine-2018-hl2-src-master.tar.xz archived-source-engine-2018-hl2-src-master.zip | |
Diffstat (limited to 'hammer/mapquadbounds.h')
| -rw-r--r-- | hammer/mapquadbounds.h | 67 |
1 files changed, 67 insertions, 0 deletions
diff --git a/hammer/mapquadbounds.h b/hammer/mapquadbounds.h new file mode 100644 index 0000000..0ef22ea --- /dev/null +++ b/hammer/mapquadbounds.h @@ -0,0 +1,67 @@ +//========= Copyright Valve Corporation, All rights reserved. ============// +// +// Purpose: A helper that measures the extents of the only non-NODRAW face of +// its only solid sibling. Writes the extents as four vector keyvalues: +// +// lowerleft +// upperleft +// lowerright +// upperright +// +// ASSUMPTIONS: +// +// 1. Only one solid sibling. +// 2. That solid only has one face with a texture other than "toolsnodraw". +// +// $NoKeywords: $ +//=============================================================================// + +#ifndef MAPQUADBOUNDS_H +#define MAPQUADBOUNDS_H +#pragma once + +#include "MapHelper.h" + + +class CHelperInfo; +class CRender3D; + + +class CMapQuadBounds : public CMapHelper +{ + public: + + DECLARE_MAPCLASS(CMapQuadBounds,CMapHelper) + + // + // Factory for building from a list of string parameters. + // + static CMapClass *CreateQuadBounds(CHelperInfo *pInfo, CMapEntity *pParent); + + // + // Construction/destruction: + // + CMapQuadBounds(void); + ~CMapQuadBounds(void); + + void PresaveWorld(void); + + virtual CMapClass *Copy(bool bUpdateDependencies); + virtual CMapClass *CopyFrom(CMapClass *pFrom, bool bUpdateDependencies); + + int SerializeRMF(std::fstream &File, BOOL bRMF) { return(0); } + int SerializeMAP(std::fstream &File, BOOL bRMF) { return(0); } + + bool IsVisualElement(void) { return(false); } // Only visible when the parent entity is selected. + + const char* GetDescription() { return("Quad bounds helper"); } + + protected: + Vector m_vLowerLeft; + Vector m_vUpperLeft; + Vector m_vLowerRight; + Vector m_vUpperRight; + int m_nError; +}; + +#endif // MAPQUADBOUNDS_H |