summaryrefslogtreecommitdiffstats
path: root/src/UI/Window.cpp
diff options
context:
space:
mode:
authorTiger Wang <ziwei.tiger@hotmail.co.uk>2014-09-27 19:40:00 +0200
committerTiger Wang <ziwei.tiger@hotmail.co.uk>2014-09-27 19:40:00 +0200
commitd1814d2d67cdaa4fbcbd10a1af290412c29441af (patch)
treeeb132621bef87b82311f70ead69694c4c88690c9 /src/UI/Window.cpp
parente.t.c. -> etc. (diff)
parentMerge pull request #1461 from mc-server/RedstoneFix (diff)
downloadcuberite-d1814d2d67cdaa4fbcbd10a1af290412c29441af.tar
cuberite-d1814d2d67cdaa4fbcbd10a1af290412c29441af.tar.gz
cuberite-d1814d2d67cdaa4fbcbd10a1af290412c29441af.tar.bz2
cuberite-d1814d2d67cdaa4fbcbd10a1af290412c29441af.tar.lz
cuberite-d1814d2d67cdaa4fbcbd10a1af290412c29441af.tar.xz
cuberite-d1814d2d67cdaa4fbcbd10a1af290412c29441af.tar.zst
cuberite-d1814d2d67cdaa4fbcbd10a1af290412c29441af.zip
Diffstat (limited to 'src/UI/Window.cpp')
-rw-r--r--src/UI/Window.cpp28
1 files changed, 28 insertions, 0 deletions
diff --git a/src/UI/Window.cpp b/src/UI/Window.cpp
index fd80a017d..d83336f75 100644
--- a/src/UI/Window.cpp
+++ b/src/UI/Window.cpp
@@ -58,6 +58,34 @@ cWindow::~cWindow()
+const AString cWindow::GetWindowTypeName(void) const
+{
+ switch (m_WindowType)
+ {
+ case wtChest: return "minecraft:chest";
+ case wtWorkbench: return "minecraft:crafting_table";
+ case wtFurnace: return "minecraft:furnace";
+ case wtDropSpenser: return "minecraft:dispenser";
+ case wtEnchantment: return "minecraft:enchanting_table";
+ case wtBrewery: return "minecraft:brewing_stand";
+ case wtNPCTrade: return "minecraft:villager";
+ case wtBeacon: return "minecraft:beacon";
+ case wtAnvil: return "minecraft:anvil";
+ case wtHopper: return "minecraft:hopper";
+ case wtDropper: return "minecraft:dropper";
+ case wtAnimalChest: return "EntityHorse";
+ default:
+ {
+ ASSERT(!"Unknown inventory type!");
+ return "";
+ }
+ }
+}
+
+
+
+
+
int cWindow::GetNumSlots(void) const
{
int res = 0;