mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2024-12-28 18:18:52 +00:00
27 lines
557 B
C++
27 lines
557 B
C++
#include "custommarkerstate.hpp"
|
|
|
|
#include "esmreader.hpp"
|
|
#include "esmwriter.hpp"
|
|
|
|
namespace ESM
|
|
{
|
|
|
|
void CustomMarker::save(ESMWriter& esm) const
|
|
{
|
|
esm.writeHNT("POSX", mWorldX);
|
|
esm.writeHNT("POSY", mWorldY);
|
|
esm.writeCellId(mCell);
|
|
if (!mNote.empty())
|
|
esm.writeHNString("NOTE", mNote);
|
|
}
|
|
|
|
void CustomMarker::load(ESMReader& esm)
|
|
{
|
|
esm.getHNT(mWorldX, "POSX");
|
|
esm.getHNT(mWorldY, "POSY");
|
|
mCell = esm.getCellId();
|
|
mNote = esm.getHNOString("NOTE");
|
|
}
|
|
|
|
}
|