You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
#include "loadligh.hpp"
|
|
|
|
|
|
|
|
#include "esm_reader.hpp"
|
|
|
|
#include "esm_writer.hpp"
|
|
|
|
|
|
|
|
namespace ESM
|
|
|
|
{
|
|
|
|
|
|
|
|
void Light::load(ESMReader &esm)
|
|
|
|
{
|
|
|
|
mModel = esm.getHNString("MODL");
|
|
|
|
mName = esm.getHNOString("FNAM");
|
|
|
|
mIcon = esm.getHNOString("ITEX");
|
|
|
|
assert(sizeof(mData) == 24);
|
|
|
|
esm.getHNT(mData, "LHDT", 24);
|
|
|
|
mScript = esm.getHNOString("SCRI");
|
|
|
|
mSound = esm.getHNOString("SNAM");
|
|
|
|
}
|
|
|
|
void Light::save(ESMWriter &esm)
|
|
|
|
{
|
|
|
|
esm.writeHNCString("MODL", mModel);
|
|
|
|
esm.writeHNOCString("FNAM", mName);
|
|
|
|
esm.writeHNOCString("ITEX", mIcon);
|
|
|
|
esm.writeHNT("LHDT", mData, 24);
|
|
|
|
esm.writeHNOCString("SCRI", mScript);
|
|
|
|
esm.writeHNOCString("SNAM", mSound);
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|