summaryrefslogtreecommitdiff
path: root/src/player.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/player.h')
-rw-r--r--src/player.h11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/player.h b/src/player.h
index aa38996a5..a5cc7123f 100644
--- a/src/player.h
+++ b/src/player.h
@@ -226,9 +226,16 @@ public:
void serialize(std::ostream &os);
void deSerialize(std::istream &is, std::string playername);
- bool checkModified()
+ bool checkModified() const
{
- return m_dirty;
+ return m_dirty || inventory.checkModified();
+ }
+
+ void setModified(const bool x)
+ {
+ m_dirty = x;
+ if (x == false)
+ inventory.setModified(x);
}
bool touching_ground;