2011-04-08 17:58:21 +04:00
|
|
|
#include "loadglob.hpp"
|
|
|
|
|
2013-09-24 13:17:28 +02:00
|
|
|
#include "defs.hpp"
|
|
|
|
|
2011-04-08 17:58:21 +04:00
|
|
|
namespace ESM
|
|
|
|
{
|
2013-09-24 13:17:28 +02:00
|
|
|
unsigned int Global::sRecordId = REC_GLOB;
|
|
|
|
|
2013-03-05 08:02:05 +01:00
|
|
|
void Global::load (ESMReader &esm)
|
2013-02-28 11:50:29 +01:00
|
|
|
{
|
2013-03-04 14:32:59 +01:00
|
|
|
mValue.read (esm, ESM::Variant::Format_Global);
|
2013-02-28 11:50:29 +01:00
|
|
|
}
|
2011-04-08 17:58:21 +04:00
|
|
|
|
2013-09-16 12:32:35 +02:00
|
|
|
void Global::save (ESMWriter &esm) const
|
2012-04-06 21:04:30 +02:00
|
|
|
{
|
2013-03-04 14:32:59 +01:00
|
|
|
mValue.write (esm, ESM::Variant::Format_Global);
|
2012-04-06 21:04:30 +02:00
|
|
|
}
|
2011-04-08 17:58:21 +04:00
|
|
|
|
2012-12-03 22:16:02 +01:00
|
|
|
void Global::blank()
|
|
|
|
{
|
2013-03-04 14:32:59 +01:00
|
|
|
mValue.setType (ESM::VT_None);
|
2012-12-03 22:16:02 +01:00
|
|
|
}
|
|
|
|
|
2012-11-29 14:45:34 +01:00
|
|
|
bool operator== (const Global& left, const Global& right)
|
|
|
|
{
|
2013-03-04 14:32:59 +01:00
|
|
|
return left.mId==right.mId && left.mValue==right.mValue;
|
2012-11-29 14:45:34 +01:00
|
|
|
}
|
2011-04-08 17:58:21 +04:00
|
|
|
}
|