From e0537a3253022246d473bc179a3d9a6629562b14 Mon Sep 17 00:00:00 2001 From: Marc Zinnschlag Date: Tue, 28 Jan 2014 13:53:24 +0100 Subject: [PATCH] made object state polymorphic --- components/esm/objectstate.cpp | 4 +++- components/esm/objectstate.hpp | 6 ++++-- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/components/esm/objectstate.cpp b/components/esm/objectstate.cpp index 21585e09de..6aa8205991 100644 --- a/components/esm/objectstate.cpp +++ b/components/esm/objectstate.cpp @@ -46,4 +46,6 @@ void ESM::ObjectState::save (ESMWriter &esm, bool inInventory) const esm.writeHNT ("POS_", mPosition, 24); esm.writeHNT ("LROT", mLocalRotation, 12); } -} \ No newline at end of file +} + +ESM::ObjectState::~ObjectState() {} \ No newline at end of file diff --git a/components/esm/objectstate.hpp b/components/esm/objectstate.hpp index 34226ea91a..9c9ca5f2e8 100644 --- a/components/esm/objectstate.hpp +++ b/components/esm/objectstate.hpp @@ -26,8 +26,10 @@ namespace ESM ESM::Position mPosition; float mLocalRotation[3]; - void load (ESMReader &esm); - void save (ESMWriter &esm, bool inInventory = false) const; + virtual void load (ESMReader &esm); + virtual void save (ESMWriter &esm, bool inInventory = false) const; + + virtual ~ObjectState(); }; }