NPCs.txt is just to quickly see the NPC ID of the specified trainer.
Edit RematchNextTarget.lua's functions getAllianceRoute or getHordeRoute depending on your faction.