aboutsummaryrefslogtreecommitdiff
path: root/src/game.cpp
diff options
context:
space:
mode:
authorPerttu Ahola <celeron55@gmail.com>2011-06-18 00:46:50 +0300
committerPerttu Ahola <celeron55@gmail.com>2011-06-18 00:46:50 +0300
commitda692355e84f8d1e5210c3c89daf775cf23ec38b (patch)
tree9298dad19f545fd5496a994e186027de589cb934 /src/game.cpp
parente7580d2804d29afb486f4eb2bd4dfb94f7181824 (diff)
downloadminetest-da692355e84f8d1e5210c3c89daf775cf23ec38b.tar.gz
minetest-da692355e84f8d1e5210c3c89daf775cf23ec38b.tar.bz2
minetest-da692355e84f8d1e5210c3c89daf775cf23ec38b.zip
Created and moved stuff to content_nodemeta.{h,cpp}
Diffstat (limited to 'src/game.cpp')
-rw-r--r--src/game.cpp13
1 files changed, 11 insertions, 2 deletions
diff --git a/src/game.cpp b/src/game.cpp
index 09f06f4f6..b11547679 100644
--- a/src/game.cpp
+++ b/src/game.cpp
@@ -34,6 +34,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
// TODO: Move content-aware stuff to separate file
#include "content_mapnode.h"
+#include "content_nodemeta.h"
/*
Setting this to 1 enables a special camera mode that forces
@@ -1730,7 +1731,11 @@ void the_game(
dstream<<"Chest node right-clicked"<<std::endl;
//ChestNodeMetadata *chestmeta = (ChestNodeMetadata*)meta;
-
+
+ /*
+ Construct the unique identification string of this
+ chest's inventory
+ */
std::string chest_inv_id;
chest_inv_id += "nodemeta:";
chest_inv_id += itos(nodepos.X);
@@ -1738,7 +1743,11 @@ void the_game(
chest_inv_id += itos(nodepos.Y);
chest_inv_id += ",";
chest_inv_id += itos(nodepos.Z);
-
+
+ /*
+ Create a menu with the player's inventory and the
+ chest's inventory
+ */
GUIInventoryMenu *menu =
new GUIInventoryMenu(guienv, guiroot, -1,
&g_menumgr, v2s16(8,9),