From 05b098141abf401fe74586e1b2fd8a143d045ca5 Mon Sep 17 00:00:00 2001 From: Peter Maloney Date: Mon, 20 Jul 2015 00:00:38 +0200 Subject: [PATCH] fixed another forward declaration issue --- technic/machines/other/anchor.lua | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/technic/machines/other/anchor.lua b/technic/machines/other/anchor.lua index b5f3f39..0b2b100 100644 --- a/technic/machines/other/anchor.lua +++ b/technic/machines/other/anchor.lua @@ -55,15 +55,6 @@ local function forceload_off(meta) end technic.forceload_off = forceload_off --- computes the forceload positions (using compute_forceload_positions) and tries to force load all of them, and records them in meta "forceloaded" --- pos - position of the anchor node --- meta - contains "radius" (to be read) and "forceloaded" (to be written) -local function forceload_on(pos, meta) - local want_flposes = compute_forceload_positions(pos, meta) - forceload_on_flposes(want_flposes, meta) - return -end - local function forceload_on_flposes(want_flposes, meta) local have_flposes = {} for _, p in ipairs(want_flposes) do @@ -75,6 +66,15 @@ local function forceload_on_flposes(want_flposes, meta) end technic.forceload_on_flposes = forceload_on_flposes +-- computes the forceload positions (using compute_forceload_positions) and tries to force load all of them, and records them in meta "forceloaded" +-- pos - position of the anchor node +-- meta - contains "radius" (to be read) and "forceloaded" (to be written) +local function forceload_on(pos, meta) + local want_flposes = compute_forceload_positions(pos, meta) + forceload_on_flposes(want_flposes, meta) + return +end + local function set_display(pos, meta) meta:set_string("infotext", S(meta:get_int("enabled") ~= 0 and "%s Enabled" or "%s Disabled"):format(desc)) meta:set_string("formspec",