Clear the server progs data when loading progs.

The baseline data doesn't matter so much, but the pointer fields relied on
the progs engine clearing them. I forgot about this :/
This commit is contained in:
Bill Currie 2010-12-09 21:35:21 +09:00
parent 87acf89404
commit 51009cdc4b
2 changed files with 4 additions and 0 deletions

View file

@ -502,6 +502,8 @@ SV_LoadProgs (void)
if (!sv_pr_state.progs)
Host_Error ("SV_LoadProgs: couldn't load %s", progs_name);
memset (sv_data, 0, sizeof (sv_data));
// init the data field of the edicts
for (i = 0; i < sv.max_edicts; i++) {
edict_t *ent = EDICT_NUM (&sv_pr_state, i);

View file

@ -523,6 +523,8 @@ SV_LoadProgs (void)
if (!sv_pr_state.progs)
Sys_Error ("SV_LoadProgs: couldn't load %s", progs_name);
memset (sv_data, 0, sizeof (sv_data));
// init the data field of the edicts
for (i = 0; i < MAX_EDICTS; i++) {
edict_t *ent = EDICT_NUM (&sv_pr_state, i);