1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-01-12 03:36:32 +00:00
OpenMW/components/esm/loadbody.cpp

26 lines
478 B
C++
Raw Normal View History

#include "loadbody.hpp"
#include "esmreader.hpp"
#include "esmwriter.hpp"
#include "defs.hpp"
2012-09-17 07:37:50 +00:00
namespace ESM
{
unsigned int BodyPart::sRecordId = REC_BODY;
void BodyPart::load(ESMReader &esm)
{
2012-09-17 07:37:50 +00:00
mModel = esm.getHNString("MODL");
mRace = esm.getHNOString("FNAM");
2012-09-17 07:37:50 +00:00
esm.getHNT(mData, "BYDT", 4);
}
void BodyPart::save(ESMWriter &esm) const
{
2012-09-17 07:37:50 +00:00
esm.writeHNCString("MODL", mModel);
esm.writeHNOCString("FNAM", mRace);
2012-09-17 07:37:50 +00:00
esm.writeHNT("BYDT", mData, 4);
}
}