forked from teamnwah/openmw-tes3coop
added filter record (will not be used in OpenMW prior to 1.1)
parent
66534a45da
commit
6f90e071f4
@ -0,0 +1,20 @@
|
||||
|
||||
#include "filter.hpp"
|
||||
|
||||
#include "esmreader.hpp"
|
||||
#include "esmwriter.hpp"
|
||||
|
||||
void ESM::Filter::load (ESMReader& esm)
|
||||
{
|
||||
mFilter = esm.getHNString ("FILT");
|
||||
}
|
||||
|
||||
void ESM::Filter::save (ESMWriter& esm)
|
||||
{
|
||||
esm.writeHNCString ("FILT", mFilter);
|
||||
}
|
||||
|
||||
void ESM::Filter::blank()
|
||||
{
|
||||
mFilter.clear();
|
||||
}
|
@ -0,0 +1,25 @@
|
||||
#ifndef COMPONENTS_ESM_FILTER_H
|
||||
#define COMPONENTS_ESM_FILTER_H
|
||||
|
||||
#include <string>
|
||||
|
||||
namespace ESM
|
||||
{
|
||||
class ESMReader;
|
||||
class ESMWriter;
|
||||
|
||||
struct Filter
|
||||
{
|
||||
std::string mId;
|
||||
|
||||
std::string mFilter;
|
||||
|
||||
void load (ESMReader& esm);
|
||||
void save (ESMWriter& esm);
|
||||
|
||||
void blank();
|
||||
///< Set record to default state (does not touch the ID).
|
||||
};
|
||||
}
|
||||
|
||||
#endif
|
Loading…
Reference in New Issue