#define VCMI_DLL #include "../stdafx.h" #include "CSpellHandler.h" #include "CLodHandler.h" #include "../lib/VCMI_Lib.h" #include extern CLodHandler *bitmaph; void CSpellHandler::loadSpells() { std::string buf = bitmaph->getTextFile("SPTRAITS.TXT"), pom; int andame = buf.size(), i=0; //buf iterator for(int z=0; z<5; ++z) loadToIt(pom,buf,i,3); bool combSpells=false; //true, if we are reading combat spells bool creatureAbility=false; //if true, only creature can use this spell int ifHit = 0; while(i>dump; //reading exact info int spellID; ast>>spellID; while(spellID != -1) { int buf; ast>>buf; spells[spellID].positiveness = buf; ast>>spellID; } } }