From 306c025713487b20a20e32e33277d2f215a70832 Mon Sep 17 00:00:00 2001 From: TenPlus1 Date: Sun, 5 Jun 2016 11:39:20 +0100 Subject: Code tweak and tidy --- dirt.lua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'dirt.lua') diff --git a/dirt.lua b/dirt.lua index c3f4c46..f68cb8d 100644 --- a/dirt.lua +++ b/dirt.lua @@ -108,13 +108,13 @@ minetest.register_abm({ "group:ethereal_grass") -- count new grass nodes - for _,p in pairs(dirts) do + for n = 1, #dirts do - num = grasses[p] or 0 + num = grasses[dirts[n]] or 0 if num > curr_max then curr_max = num - curr_type = p + curr_type = dirts[n] end end -- cgit v1.2.3