mirror of
https://github.com/nzp-team/fteqw.git
synced 2024-11-26 05:41:52 +00:00
try to be more verbose with null functions called from the engine.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4652 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
parent
589b09ae1d
commit
6cc33d7d08
4 changed files with 13 additions and 3 deletions
|
@ -5025,7 +5025,10 @@ void CSQC_Event_Think(world_t *w, wedict_t *s)
|
|||
*csqcg.other = EDICT_TO_PROG(w->progs, (edict_t*)w->edicts);
|
||||
*csqcg.simtime = w->physicstime;
|
||||
|
||||
PR_ExecuteProgram (w->progs, s->v->think);
|
||||
if (!s->v->think)
|
||||
Con_Printf("CSQC entity \"%s\" has nextthink with no think function\n", PR_GetString(w->progs, s->v->classname));
|
||||
else
|
||||
PR_ExecuteProgram (w->progs, s->v->think);
|
||||
}
|
||||
|
||||
void CSQC_Event_Sound (float *origin, wedict_t *wentity, int channel, char *sample, int volume, float attenuation, int pitchadj)
|
||||
|
|
|
@ -1365,7 +1365,11 @@ void PDECL PR_ExecuteProgram (pubprogfuncs_t *ppf, func_t fnum)
|
|||
{
|
||||
// if (pr_global_struct->self)
|
||||
// ED_Print (PROG_TO_EDICT(pr_global_struct->self));
|
||||
#ifdef __GNUC__
|
||||
printf("PR_ExecuteProgram: NULL function from exe (address %p)\n", __builtin_return_address(0));
|
||||
#else
|
||||
printf("PR_ExecuteProgram: NULL function from exe\n");
|
||||
#endif
|
||||
// Host_Error ("PR_ExecuteProgram: NULL function from exe");
|
||||
|
||||
// PR_MoveParms(0, pr_typecurrent);
|
||||
|
|
|
@ -533,7 +533,10 @@ void SVPR_Event_Think(world_t *w, wedict_t *s)
|
|||
{
|
||||
pr_global_struct->self = EDICT_TO_PROG(w->progs, s);
|
||||
pr_global_struct->other = EDICT_TO_PROG(w->progs, w->edicts);
|
||||
PR_ExecuteProgram (w->progs, s->v->think);
|
||||
if (!s->v->think)
|
||||
Con_Printf("SSQC entity \"%s\" has nextthink with no think function\n", PR_GetString(w->progs, s->v->classname));
|
||||
else
|
||||
PR_ExecuteProgram (w->progs, s->v->think);
|
||||
}
|
||||
|
||||
qboolean SVPR_Event_ContentsTransition(world_t *w, wedict_t *ent, int oldwatertype, int newwatertype)
|
||||
|
|
|
@ -1716,7 +1716,7 @@ void SV_Begin_Core(client_t *split)
|
|||
{
|
||||
eval_t *eval, *eval2;
|
||||
eval = PR_FindGlobal(svprogfuncs, "ClientReEnter", 0, NULL);
|
||||
if (eval && split->spawninfo)
|
||||
if (eval && eval->function && split->spawninfo)
|
||||
{
|
||||
globalvars_t *pr_globals = PR_globals(svprogfuncs, PR_CURRENT);
|
||||
int j;
|
||||
|
|
Loading…
Reference in a new issue