if (prog == NULL)
return;
- prog->funcoffsets.SV_Shutdown = 0; // don't call SV_Shutdown on crash
+ PRVM_serverfunction(SV_Shutdown) = 0; // don't call SV_Shutdown on crash
if( prog->depth > 0 )
{
if (!fnum || fnum >= (unsigned int)prog->numfunctions)
{
- if (prog->globaloffsets.self >= 0 && PRVM_GLOBALFIELDVALUE(prog->globaloffsets.self)->edict)
- PRVM_ED_Print(PRVM_PROG_TO_EDICT(PRVM_GLOBALFIELDVALUE(prog->globaloffsets.self)->edict), NULL);
+ if (PRVM_allglobaledict(self))
+ PRVM_ED_Print(PRVM_PROG_TO_EDICT(PRVM_allglobaledict(self)), NULL);
PRVM_ERROR ("MVM_ExecuteProgram: %s", errormessage);
}
if (!fnum || fnum >= (unsigned int)prog->numfunctions)
{
- if (prog->globaloffsets.self >= 0 && PRVM_GLOBALFIELDVALUE(prog->globaloffsets.self)->edict)
- PRVM_ED_Print(PRVM_PROG_TO_EDICT(PRVM_GLOBALFIELDVALUE(prog->globaloffsets.self)->edict), NULL);
+ if (PRVM_allglobaledict(self))
+ PRVM_ED_Print(PRVM_PROG_TO_EDICT(PRVM_allglobaledict(self)), NULL);
PRVM_ERROR ("CLVM_ExecuteProgram: %s", errormessage);
}
if (!fnum || fnum >= (unsigned int)prog->numfunctions)
{
- if (prog->globaloffsets.self >= 0 && PRVM_GLOBALFIELDVALUE(prog->globaloffsets.self)->edict)
- PRVM_ED_Print(PRVM_PROG_TO_EDICT(PRVM_GLOBALFIELDVALUE(prog->globaloffsets.self)->edict), NULL);
+ if (PRVM_allglobaledict(self))
+ PRVM_ED_Print(PRVM_PROG_TO_EDICT(PRVM_allglobaledict(self)), NULL);
PRVM_ERROR ("SVVM_ExecuteProgram: %s", errormessage);
}