diff --git a/apps/essimporter/importacdt.cpp b/apps/essimporter/importacdt.cpp index 136183668..9a062484b 100644 --- a/apps/essimporter/importacdt.cpp +++ b/apps/essimporter/importacdt.cpp @@ -60,10 +60,6 @@ namespace ESSImport if (esm.isNextSub("PWPS")) esm.skipHSub(); - // unsure at which point between LSTN and CHRD - if (esm.isNextSub("APUD")) - esm.skipHSub(); // 40 bytes, starts with string "ancestor guardian". maybe spellcasting in progress? - if (esm.isNextSub("WNAM")) { std::string id = esm.getHString(); @@ -77,6 +73,20 @@ namespace ESSImport esm.skipHSub(); // 4 byte, 0 } + while (esm.isNextSub("APUD")) + { + // used power + esm.getSubHeader(); + std::string id = esm.getString(32); + (void)id; + // timestamp can't be used: this is the total hours passed, calculated by + // timestamp = 24 * (365 * year + cumulativeDays[month] + day) + // unfortunately cumulativeDays[month] is not clearly defined, + // in the (non-MCP) vanilla version the first month was missing, but MCP added it. + double timestamp; + esm.getT(timestamp); + } + // FIXME: not all actors have this, add flag if (esm.isNextSub("CHRD")) // npc only esm.getHExact(mSkills, 27*2*sizeof(int));