Fixed npc-duplication bug