Debian Codegraph @

editor/EPath.h

raw symbols SCIP
1 /*
2 * Descent 3
3 * Copyright (C) 2024 Parallax Software
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation, either version 3 of the License, or
8 * (at your option) any later version.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with this program. If not, see <http://www.gnu.org/licenses/>.
17
18 --- HISTORICAL COMMENTS FOLLOW ---
19
20 * $Logfile: /DescentIII/Main/editor/EPath.h $
21 * $Revision: 1.1.1.1 $
22 * $Date: 2003-08-26 03:57:38 $
23 * $Author: kevinb $
24 *
25 * Header for epaths.cpp
26 *
27 * $Log: not supported by cvs2svn $
28 *
29 * 3 2/03/99 6:57p Chris
30 * Added the "Move node to current object" function
31 *
32 * 2 2/10/98 10:48a Matt
33 * Moved editor code from gamepath.cpp to epath.cpp
34 *
35 * 1 2/10/98 10:13a Matt
36 *
37 */
38
39 #include "vecmat.h"
40 #include "gamepath.h"
41
42 extern uint8_t Show_paths;
43
44 // Allocs a gamepath that a robot will follow. Returns an index into the GamePaths
45 // array
46 int AllocGamePath(void);
47
48 // Given a path number, and a node number in that path, adds another node after the
49 // specified node
50 // Returns the index number of the new node
51 // If nodenum is -1, this node couldn't be added
52 // Flags are passed via the flags field
53 int InsertNodeIntoPath(int pathnum, int nodenum, int flags);
54
55 void FreeGamePath(int n);
56
57 // Given a pathnum and a node index, deletes that node and moves all the following nodes down
58 // by one
59 void DeleteNodeFromPath(int pathnum, int nodenum);
60
61 // Given a path number and a node, it moves the node by the change in position (if the new position is valid)
62 int MovePathNode(int pathnum, int nodenum, vector *delta_pos);
63
64 // Given a path number and a node, it moves the node to the position (if the new position is valid)
65 int MovePathNodeToPos(int pathnum, int nodenum, vector *pos);
66
67 // Gets next path from n that has actually been alloced
68 int GetNextPath(int n);
69 // Gets previous path from n that has actually been alloced
70 int GetPrevPath(int n);
71
72 // returns the index of the first path (from 0) alloced
73 // returns -1 if there are no paths
74 int GetFirstPath();
75
76 // draws a vector number
77 void DrawNumber(int num, vector pos, float size);
78
79 class grViewport;
80 // draws all the paths
81 void DrawAllPaths(grViewport *vp, vector *viewer_eye, matrix *viewer_orient, float zoom);