Nuclide
Software Development Kit for id Tech
Main Page
Related Pages
Modules
Classes
Files
File List
File Members
nodes.h
Go to the documentation of this file.
1
/*
2
* Copyright (c) 2016-2020 Vera Visions LLC.
3
*
4
* Permission to use, copy, modify, and distribute this software for any
5
* purpose with or without fee is hereby granted, provided that the above
6
* copyright notice and this permission notice appear in all copies.
7
*
8
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
9
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
10
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
11
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
12
* WHATSOEVER RESULTING FROM LOSS OF MIND, USE, DATA OR PROFITS, WHETHER
13
* IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING
14
* OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
15
*/
16
21
/* parse info_node entities and convert them to FTE compatible routing data */
22
#define NODE_DEBUG
23
#define COST_INFINITE 99999
24
26
typedef
struct
{
27
vector
m_vecOrigin
;
28
float
m_flRadius
;
/* used for picking the closest waypoint. aka proximity weight. also relaxes routes inside the area. */
29
struct
neighbour_s
30
{
31
int
m_iNode
;
32
float
m_flCost
;
33
int
m_iFlags
;
34
} *m_pNeighbour;
35
int
m_numNeighbours
;
36
}
node_t
;
37
38
node_t
*
g_pNodes
;
39
int
g_iNodes
;
40
46
void
Nodes_Flush
(
void
);
47
void
Nodes_Init
(
void
);
48
bool
Nodes_Available
(
void
);
49
// end of nav
Nodes_Flush
void Nodes_Flush(void)
Definition:
nodes.qc:188
Nodes_Available
bool Nodes_Available(void)
Definition:
nodes.qc:113
Nodes_Init
void Nodes_Init(void)
Definition:
nodes.qc:173
g_iNodes
int g_iNodes
Definition:
nodes.h:39
g_pNodes
node_t * g_pNodes
Definition:
nodes.h:38
node_t::neighbour_s
Definition:
nodes.h:30
node_t::neighbour_s::m_iFlags
int m_iFlags
Definition:
nodes.h:33
node_t::neighbour_s::m_iNode
int m_iNode
Definition:
nodes.h:31
node_t::neighbour_s::m_flCost
float m_flCost
Definition:
nodes.h:32
node_t
Data holding Node entries.
Definition:
nodes.h:26
node_t::m_numNeighbours
int m_numNeighbours
Definition:
nodes.h:35
node_t::m_vecOrigin
vector m_vecOrigin
Definition:
nodes.h:27
node_t::m_flRadius
float m_flRadius
Definition:
nodes.h:28
src
nav
nodes.h
Generated by
1.9.3