- Con_Print("No spawn function for:\n");
- PRVM_ED_Print(ent, NULL);
+ // self = ent
+ PRVM_GLOBALFIELDVALUE(prog->globaloffsets.self)->edict = PRVM_EDICT_TO_PROG(ent);
+ PRVM_ExecuteProgram (prog->funcoffsets.SV_OnEntityNoSpawnFunction, "QC function SV_OnEntityNoSpawnFunction is missing");
+ }
+ else
+ {
+ if (developer.integer) // don't confuse non-developers with errors
+ {
+ Con_Print("No spawn function for:\n");
+ PRVM_ED_Print(ent, NULL);
+ }
+ PRVM_ED_Free (ent);
+ continue;