summaryrefslogtreecommitdiff
path: root/tomato.lua
diff options
context:
space:
mode:
authorxisd <zlexis.dnl@googlemail.com>2016-10-18 18:13:59 +0200
committerAuke Kok <sofar+github@foo-projects.org>2016-10-18 09:13:59 -0700
commite6421d8d495c4415eeae80c7b1a2ce20d55e443d (patch)
tree1f2c38e7e72f7bd5dbd04888d7bc758d007326af /tomato.lua
parent65729b9d33fde507a4044b25cd29fba2d8a5eb50 (diff)
Intllib (#5)
Support for translation via intllib.
Diffstat (limited to 'tomato.lua')
-rw-r--r--tomato.lua14
1 files changed, 8 insertions, 6 deletions
diff --git a/tomato.lua b/tomato.lua
index 8d4ea08..d14658e 100644
--- a/tomato.lua
+++ b/tomato.lua
@@ -10,10 +10,13 @@ of the license, or (at your option) any later version.
--]]
+-- Intllib
+local S = crops.intllib
+
local wateruse = 1
minetest.register_node("crops:tomato_seed", {
- description = "tomato seed",
+ description = S("Tomato seed"),
inventory_image = "crops_tomato_seed.png",
wield_image = "crops_tomato_seed.png",
tiles = { "crops_tomato_plant_1.png" },
@@ -43,7 +46,7 @@ minetest.register_node("crops:tomato_seed", {
for stage = 1, 4 do
minetest.register_node("crops:tomato_plant_" .. stage , {
- description = "tomato plant",
+ description = S("Tomato plant"),
tiles = { "crops_tomato_plant_" .. stage .. ".png" },
drawtype = "plantlike",
waving = 1,
@@ -62,7 +65,7 @@ minetest.register_node("crops:tomato_plant_" .. stage , {
end
minetest.register_node("crops:tomato_plant_5" , {
- description = "tomato plant",
+ description = S("Tomato plant"),
tiles = { "crops_tomato_plant_5.png" },
drawtype = "plantlike",
waving = 1,
@@ -96,7 +99,7 @@ minetest.register_node("crops:tomato_plant_5" , {
})
minetest.register_node("crops:tomato_plant_6", {
- description = "tomato plant",
+ description = S("Tomato plant"),
tiles = { "crops_tomato_plant_6.png" },
drawtype = "plantlike",
waving = 1,
@@ -114,7 +117,7 @@ minetest.register_node("crops:tomato_plant_6", {
})
minetest.register_craftitem("crops:tomato", {
- description = "Tomato",
+ description = S("Tomato"),
inventory_image = "crops_tomato.png",
on_use = minetest.item_eat(1)
})
@@ -194,4 +197,3 @@ crops.register({ name = "crops:tomato_plant_2", properties = properties })
crops.register({ name = "crops:tomato_plant_3", properties = properties })
crops.register({ name = "crops:tomato_plant_4", properties = properties })
crops.register({ name = "crops:tomato_plant_5", properties = properties })
-