Modified CEntityGenerator.getNext to set pEdict to NULL when EdictFromIndex fails instead of returning NULL.