mirror of
https://github.com/DarkPlacesEngine/gmqcc.git
synced 2024-11-23 20:33:05 +00:00
Add the empty globaldef/fielddef to the object, savegame skips that null-def when saving variables...
This commit is contained in:
parent
76b0eb0cb7
commit
9f411a533a
1 changed files with 3 additions and 0 deletions
3
code.c
3
code.c
|
@ -68,6 +68,7 @@ uint32_t code_entfields;
|
||||||
void code_init() {
|
void code_init() {
|
||||||
prog_section_function empty_function = {0,0,0,0,0,0,0,{0}};
|
prog_section_function empty_function = {0,0,0,0,0,0,0,{0}};
|
||||||
prog_section_statement empty_statement = {0,{0},{0},{0}};
|
prog_section_statement empty_statement = {0,{0},{0},{0}};
|
||||||
|
prog_section_def empty_def = {0, 0, 0};
|
||||||
int i = 0;
|
int i = 0;
|
||||||
|
|
||||||
/* omit creation of null code */
|
/* omit creation of null code */
|
||||||
|
@ -84,6 +85,8 @@ void code_init() {
|
||||||
code_chars_add ('\0');
|
code_chars_add ('\0');
|
||||||
code_functions_add (empty_function);
|
code_functions_add (empty_function);
|
||||||
code_statements_add(empty_statement);
|
code_statements_add(empty_statement);
|
||||||
|
code_defs_add (empty_def);
|
||||||
|
code_fields_add (empty_def);
|
||||||
|
|
||||||
code_entfields = 0;
|
code_entfields = 0;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue