mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2025-01-30 12:40:42 +00:00
pr_debug.c:
capitolise CRC and add a \n to the message sv_progs.c (both nq and qw): don't bother checking the progdefs.h crc: it's just not needed any more pr_imm.c: use r instead of rep when checking the hash tables. main.c (quaq): make developer work and set com_filesize (otherwise, progs crc doesn't get set properly (com_filesize, not developer:))
This commit is contained in:
parent
33e506e943
commit
47a6f2c9b5
5 changed files with 5 additions and 7 deletions
|
@ -157,7 +157,7 @@ PR_LoadDebug (progs_t *pr)
|
||||||
}
|
}
|
||||||
pr->debug->crc = LittleShort (pr->debug->crc);
|
pr->debug->crc = LittleShort (pr->debug->crc);
|
||||||
if (pr->debug->crc != pr->crc) {
|
if (pr->debug->crc != pr->crc) {
|
||||||
Sys_Printf ("ignoring %s that doesn't match %s. (crcs: sym:%d dat:%d)",
|
Sys_Printf ("ignoring %s that doesn't match %s. (CRCs: sym:%d dat:%d)\n",
|
||||||
sym_path,
|
sym_path,
|
||||||
pr->progs_name,
|
pr->progs_name,
|
||||||
pr->debug->crc,
|
pr->debug->crc,
|
||||||
|
|
|
@ -136,8 +136,6 @@ SV_LoadProgs (void)
|
||||||
PR_LoadProgs (&sv_pr_state, sv_progs->string);
|
PR_LoadProgs (&sv_pr_state, sv_progs->string);
|
||||||
if (!sv_pr_state.progs)
|
if (!sv_pr_state.progs)
|
||||||
Host_Error ("SV_LoadProgs: couldn't load %s", sv_progs->string);
|
Host_Error ("SV_LoadProgs: couldn't load %s", sv_progs->string);
|
||||||
if (sv_pr_state.progs->crc != PROGHEADER_CRC)
|
|
||||||
Host_Error ("You must have the progs.dat from Quake installed");
|
|
||||||
// progs engine needs these globals anyway
|
// progs engine needs these globals anyway
|
||||||
sv_globals.self = sv_pr_state.globals.self;
|
sv_globals.self = sv_pr_state.globals.self;
|
||||||
sv_globals.time = sv_pr_state.globals.time;
|
sv_globals.time = sv_pr_state.globals.time;
|
||||||
|
|
|
@ -147,8 +147,6 @@ SV_LoadProgs (void)
|
||||||
PR_LoadProgs (&sv_pr_state, sv_progs->string);
|
PR_LoadProgs (&sv_pr_state, sv_progs->string);
|
||||||
if (!sv_pr_state.progs)
|
if (!sv_pr_state.progs)
|
||||||
SV_Error ("SV_LoadProgs: couldn't load %s", sv_progs->string);
|
SV_Error ("SV_LoadProgs: couldn't load %s", sv_progs->string);
|
||||||
if (sv_pr_state.progs->crc != PROGHEADER_CRC)
|
|
||||||
SV_Error ("You must have the qwprogs.dat from QuakeWorld installed");
|
|
||||||
// progs engine needs these globals anyway
|
// progs engine needs these globals anyway
|
||||||
sv_globals.self = sv_pr_state.globals.self;
|
sv_globals.self = sv_pr_state.globals.self;
|
||||||
sv_globals.time = sv_pr_state.globals.time;
|
sv_globals.time = sv_pr_state.globals.time;
|
||||||
|
|
|
@ -230,7 +230,7 @@ PR_ReuseConstant (expr_t *expr, def_t *def)
|
||||||
default:
|
default:
|
||||||
abort ();
|
abort ();
|
||||||
}
|
}
|
||||||
cn = (def_t*) Hash_Find (tab, rep);
|
cn = (def_t*) Hash_Find (tab, r);
|
||||||
if (cn) {
|
if (cn) {
|
||||||
if (def) {
|
if (def) {
|
||||||
PR_FreeLocation (def);
|
PR_FreeLocation (def);
|
||||||
|
|
|
@ -20,6 +20,7 @@ int reserved_edicts;
|
||||||
void BI_Init (progs_t *progs);
|
void BI_Init (progs_t *progs);
|
||||||
|
|
||||||
extern char *type_name[];
|
extern char *type_name[];
|
||||||
|
extern cvar_t *developer;
|
||||||
|
|
||||||
extern float *read_result; //FIXME: eww
|
extern float *read_result; //FIXME: eww
|
||||||
|
|
||||||
|
@ -43,7 +44,7 @@ main ()
|
||||||
Cvar_Get ("fs_basegame", ".", 0, 0, 0);
|
Cvar_Get ("fs_basegame", ".", 0, 0, 0);
|
||||||
Cvar_Get ("fs_userpath", ".", 0, 0, 0);
|
Cvar_Get ("fs_userpath", ".", 0, 0, 0);
|
||||||
Cvar_Get ("fs_sharepath", ".", 0, 0, 0);
|
Cvar_Get ("fs_sharepath", ".", 0, 0, 0);
|
||||||
Cvar_Get ("developer", "1", 0, 0, 0);
|
developer = Cvar_Get ("developer", "1", 0, 0, 0);
|
||||||
|
|
||||||
PR_Init_Cvars ();
|
PR_Init_Cvars ();
|
||||||
COM_Filesystem_Init_Cvars ();
|
COM_Filesystem_Init_Cvars ();
|
||||||
|
@ -64,6 +65,7 @@ main ()
|
||||||
progs.progs = Hunk_AllocName (len, "qwaq.dat");
|
progs.progs = Hunk_AllocName (len, "qwaq.dat");
|
||||||
fread (progs.progs, 1, len, f);
|
fread (progs.progs, 1, len, f);
|
||||||
fclose (f);
|
fclose (f);
|
||||||
|
com_filesize = len;
|
||||||
if (progs.progs)
|
if (progs.progs)
|
||||||
PR_LoadProgs (&progs, 0);
|
PR_LoadProgs (&progs, 0);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue