From a1be5250b80f1dd7b0b3b9c59611cdb0c0bf57a7 Mon Sep 17 00:00:00 2001 From: Auke Kok Date: Wed, 6 May 2015 23:59:25 -0700 Subject: Unify the difficulty settings into init.lua All the scaling factors are now either in the plant table or the crops.settings table. This makes end-user tuning a bit harder, but switching easier and configuring easier as well. --- melon.lua | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'melon.lua') diff --git a/melon.lua b/melon.lua index 79b93d9..a07c1bf 100644 --- a/melon.lua +++ b/melon.lua @@ -140,8 +140,8 @@ minetest.register_node("crops:melon", { minetest.register_abm({ nodenames = { "crops:melon_plant_1", "crops:melon_plant_2", "crops:melon_plant_3","crops:melon_plant_4" }, neighbors = { "group:soil" }, - interval = crops.interval, - chance = crops.chance, + interval = crops.settings.interval, + chance = crops.settings.chance, action = function(pos, node, active_object_count, active_object_count_wider) if not crops.can_grow(pos) then return @@ -161,8 +161,8 @@ minetest.register_abm({ minetest.register_abm({ nodenames = { "crops:melon_plant_5" }, neighbors = { "group:soil" }, - interval = crops.interval, - chance = crops.chance, + interval = crops.settings.interval, + chance = crops.settings.chance, action = function(pos, node, active_object_count, active_object_count_wider) if not crops.can_grow(pos) then return @@ -207,7 +207,7 @@ minetest.register_abm({ -- minetest.register_abm({ nodenames = { "crops:melon_plant_5_attached" }, - interval = crops.interval, + interval = crops.settings.interval, chance = 1, action = function(pos, node, active_object_count, active_object_count_wider) for face = 1, 4 do -- cgit v1.2.3