actually what i did was this...
Code:
int bleh () { return 0; }
int blah = 0;
// then in the ENTINDEX and INDEXENT
if (FNullEnt (pEdict)) blah = 1 / bleh();
I didn't put that in the above example just to simplify the example..
Did that to stop MSVC from complaining...
so annoying...
[edit]
okay now my ENTINDEX and INDEXENT functions look like this..
Code:
inline int ENTINDEX(edict_t *pEdict) { if (STRING (pEdict->v.classname)[0] == 0); return (*g_engfuncs.pfnIndexOfEdict)(pEdict); }
inline edict_t* INDEXENT( int iEdictNum ) { if (iEdictNum == 0) iEdictNum /= iEdictNum; return (*g_engfuncs.pfnPEntityOfEntIndex)(iEdictNum); }
still won't make it crash...
I'm really starting to think that these 2 functions aren't causing it..
[/edit]