Fixed the problem with const in NPC, added a missing include in main.h