If an npc spawns and despawns within the same frame, the despawn events occur prior to the deferred spawn events.