1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-01-25 06:35:30 +00:00
OpenMW/components/esm/loadbsgn.cpp

38 lines
706 B
C++
Raw Normal View History

#include "loadbsgn.hpp"
#include "esmreader.hpp"
#include "esmwriter.hpp"
#include "defs.hpp"
2012-09-17 11:37:50 +04:00
namespace ESM
{
unsigned int BirthSign::sRecordId = REC_BSGN;
void BirthSign::load(ESMReader &esm)
{
2012-09-17 11:37:50 +04:00
mName = esm.getHNString("FNAM");
mTexture = esm.getHNOString("TNAM");
mDescription = esm.getHNOString("DESC");
2012-09-17 11:37:50 +04:00
mPowers.load(esm);
}
2012-09-17 11:37:50 +04:00
void BirthSign::save(ESMWriter &esm) const
{
2012-09-17 11:37:50 +04:00
esm.writeHNCString("FNAM", mName);
esm.writeHNOCString("TNAM", mTexture);
esm.writeHNOCString("DESC", mDescription);
2012-09-17 11:37:50 +04:00
mPowers.save(esm);
}
2013-04-07 20:26:39 +02:00
void BirthSign::blank()
{
mName.clear();
mDescription.clear();
mTexture.clear();
mPowers.mList.clear();
}
}