Debian Codegraph @

Descent3/objinit.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/objinit.h $
21 * $Revision: 8 $
22 * $Date: 4/20/99 12:24p $
23 * $Author: Matt $
24 *
25 * Header for ObjInit.cpp
26 *
27 * $Log: /DescentIII/main/objinit.h $
28 *
29 * 8 4/20/99 12:24p Matt
30 * Re-revised the ObjInit() system. ObjInit() again does all the
31 * initialization stuff, but now it's passed a lot more information so
32 * those fields can be set before the rest of the initialization takes
33 * place.
34 *
35 * 7 4/10/99 5:56p Matt
36 * Cleaned up object initialization code, including create object & load
37 * object.
38 *
39 * 6 3/30/98 6:58p Matt
40 * When reinitializing an object, don't bash its custom script.
41 *
42 * 5 3/30/98 6:20p Matt
43 * Renamed ResetObject() to be ObjReInitAll()
44 *
45 * 4 1/18/98 9:06p Matt
46 * Changed a comment, and deleted some unused code
47 *
48 * 3 8/21/97 5:56p Samir
49 * Took out script specific stuff from ObjInit and moved to ObjScript
50 *
51 * 2 8/12/97 3:25p Samir
52 * Added prototype to initialize scripts for objects.
53 *
54 * 2 4/04/97 2:57p Matt
55 * Added code to initialize all the type-specific data for an object from
56 * the page for that object type. This means that we need to pass less
57 * info to ObjCreate(), and that we save less info in the level save file.
58 * It also makes it easy to reset all the objects when an object page has
59 * changed.
60 *
61 * 1 4/04/97 11:38a Matt
62 *
63 * $NoKeywords: $
64 */
65
66 #ifndef _OBJINIT_H
67 #define _OBJINIT_H
68
69 #include "object.h"
70
71 // Initializes a new object. All fields not passed in set to defaults.
72 // Returns 1 if ok, 0 if error
73 int ObjInit(object *objp, int type, int id, int handle, vector *pos, float creation_time,
74 int parent_handle = OBJECT_HANDLE_NONE);
75
76 // Re-copies data to each object from the appropriate page for that object type.
77 // Called after an object page has changed.
78 void ObjReInitAll(void);
79
80 #endif