2011-04-06 16:11:08 +00:00
|
|
|
#include "loadappa.hpp"
|
|
|
|
|
2012-09-23 18:41:41 +00:00
|
|
|
#include "esmreader.hpp"
|
|
|
|
#include "esmwriter.hpp"
|
2012-09-17 07:37:50 +00:00
|
|
|
|
2011-04-06 16:11:08 +00:00
|
|
|
namespace ESM
|
|
|
|
{
|
|
|
|
void Apparatus::load(ESMReader &esm)
|
|
|
|
{
|
2012-09-17 07:37:50 +00:00
|
|
|
mModel = esm.getHNString("MODL");
|
|
|
|
mName = esm.getHNString("FNAM");
|
|
|
|
esm.getHNT(mData, "AADT", 16);
|
|
|
|
mScript = esm.getHNOString("SCRI");
|
|
|
|
mIcon = esm.getHNString("ITEX");
|
2011-04-06 16:11:08 +00:00
|
|
|
}
|
2012-04-06 19:04:30 +00:00
|
|
|
void Apparatus::save(ESMWriter &esm)
|
|
|
|
{
|
2012-09-17 07:37:50 +00:00
|
|
|
esm.writeHNCString("MODL", mModel);
|
|
|
|
esm.writeHNCString("FNAM", mName);
|
|
|
|
esm.writeHNT("AADT", mData, 16);
|
|
|
|
esm.writeHNOCString("SCRI", mScript);
|
|
|
|
esm.writeHNCString("ITEX", mIcon);
|
2011-04-06 16:11:08 +00:00
|
|
|
}
|
|
|
|
}
|