summaryrefslogtreecommitdiff
path: root/technic_chests
diff options
context:
space:
mode:
authorZefram <zefram@fysh.org>2014-06-20 15:44:05 +0100
committerRealBadAngel <maciej.kasatkin@o2.pl>2014-06-21 01:20:30 +0200
commitf7d103cd96f609f6c0002074d46d661ba14c2ae5 (patch)
tree41ffe5f65ea70720d9c8279630a7219744e3a007 /technic_chests
parent23603e7f4119245227f4ec0d15a8ecb6a444c5cd (diff)
Rename default chest to "Wooden Chest"
All the chests added by technic specify their material in their description, so the description "Chest" for the default chest looks ambiguous. Rename it to seamlessly fit into the range of chest types.
Diffstat (limited to 'technic_chests')
-rw-r--r--technic_chests/init.lua1
-rw-r--r--technic_chests/locale/de.txt1
-rw-r--r--technic_chests/locale/template.txt1
-rw-r--r--technic_chests/wooden_chest.lua14
4 files changed, 17 insertions, 0 deletions
diff --git a/technic_chests/init.lua b/technic_chests/init.lua
index 6003054..99af8ad 100644
--- a/technic_chests/init.lua
+++ b/technic_chests/init.lua
@@ -8,6 +8,7 @@ technic.chests = {}
dofile(modpath.."/common.lua")
dofile(modpath.."/register.lua")
+dofile(modpath.."/wooden_chest.lua")
dofile(modpath.."/iron_chest.lua")
dofile(modpath.."/copper_chest.lua")
dofile(modpath.."/silver_chest.lua")
diff --git a/technic_chests/locale/de.txt b/technic_chests/locale/de.txt
index 373261f..e22d2c2 100644
--- a/technic_chests/locale/de.txt
+++ b/technic_chests/locale/de.txt
@@ -32,6 +32,7 @@ Gold = Gold
Iron = Eisen
Mithril = Mithril
Silver = Silber
+Wooden = Holz
# Sorting
Sort =
diff --git a/technic_chests/locale/template.txt b/technic_chests/locale/template.txt
index 61e0f04..4d422b2 100644
--- a/technic_chests/locale/template.txt
+++ b/technic_chests/locale/template.txt
@@ -30,6 +30,7 @@ Gold =
Iron =
Mithril =
Silver =
+Wooden =
# Sorting
Sort =
diff --git a/technic_chests/wooden_chest.lua b/technic_chests/wooden_chest.lua
new file mode 100644
index 0000000..8ff33b0
--- /dev/null
+++ b/technic_chests/wooden_chest.lua
@@ -0,0 +1,14 @@
+local S
+if intllib then
+ S = intllib.Getter()
+else
+ S = function(s) return s end
+end
+
+if minetest.registered_nodes["default:chest"].description == "Chest" then
+ minetest.override_item("default:chest", { description = S("%s Chest"):format(S("Wooden")) })
+end
+
+if minetest.registered_nodes["default:chest_locked"].description == "Locked Chest" then
+ minetest.override_item("default:chest_locked", { description = S("%s Locked Chest"):format(S("Wooden")) })
+end