halflife-sdk/dlls/nodes.h

54 lines
1.5 KiB
C
Raw Normal View History

1999-04-07 00:00:00 +00:00
/***
*
2001-11-08 00:00:00 +00:00
* Copyright (c) 1996-2001, Valve LLC. All rights reserved.
1999-04-07 00:00:00 +00:00
*
* This product contains software technology licensed from Id
* Software, Inc. ("Id Technology"). Id Technology (c) 1996 Id Software, Inc.
* All Rights Reserved.
*
2001-11-08 00:00:00 +00:00
* Use, distribution, and modification of this source code and/or resulting
* object code is restricted to non-commercial enhancements to products from
* Valve LLC. All other use, distribution, or modification is prohibited
* without written permission from Valve LLC.
1999-04-07 00:00:00 +00:00
*
****/
//=========================================================
// nodes.h
//=========================================================
2001-11-08 00:00:00 +00:00
#ifndef NODES_H
#define NODES_H
1999-04-07 00:00:00 +00:00
2001-11-08 00:00:00 +00:00
#define bits_NODE_GROUP_REALM 1
1999-04-07 00:00:00 +00:00
class CLink
{
public:
entvars_t *m_pLinkEnt;// the entity that blocks this connection (doors, etc)
};
class CGraph
{
public:
BOOL m_fGraphPresent;// is the graph in memory?
BOOL m_fGraphPointersSet;// are the entity pointers for the graph all set?
2001-08-29 00:00:00 +00:00
int m_cLinks;// total number of links
2001-11-08 00:00:00 +00:00
CLink *m_pLinkPool;// big list of all node connections
2001-08-29 00:00:00 +00:00
1999-04-07 00:00:00 +00:00
void InitGraph( void );
int AllocNodes ( void );
int CheckNODFile(char *szMapName);
int FLoadGraph(char *szMapName);
int FSetGraphPointers(void);
2001-11-08 00:00:00 +00:00
void ShowNodeConnections ( int iNode );
int FindNearestNode ( const Vector &vecOrigin, CBaseEntity *pEntity );
int FindNearestNode ( const Vector &vecOrigin, int afNodeTypes );
2001-08-29 00:00:00 +00:00
};
extern CGraph WorldGraph;
2001-11-08 00:00:00 +00:00
#endif // NODES_H