From 876af8f52961cd03b65d8d2ca76d38fc72269175 Mon Sep 17 00:00:00 2001 From: scrawl Date: Wed, 16 Jul 2014 20:09:42 +0200 Subject: [PATCH] Fix not saved Attacked flag (Fixes #1657) --- components/esm/creaturestats.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/components/esm/creaturestats.cpp b/components/esm/creaturestats.cpp index 0a9a36109..37f0cc63c 100644 --- a/components/esm/creaturestats.cpp +++ b/components/esm/creaturestats.cpp @@ -33,6 +33,9 @@ void ESM::CreatureStats::load (ESMReader &esm) mAlarmed = false; esm.getHNOT (mAlarmed, "ALRM"); + mAttacked = false; + esm.getHNOT (mAttacked, "ATKD"); + mHostile = false; esm.getHNOT (mHostile, "HOST"); @@ -142,6 +145,9 @@ void ESM::CreatureStats::save (ESMWriter &esm) const if (mAlarmed) esm.writeHNT ("ALRM", mAlarmed); + if (mAttacked) + esm.writeHNT ("ATKD", mAttacked); + if (mHostile) esm.writeHNT ("HOST", mHostile);