From d9602eef55649cafc94c464d58ced38bb45fd9e9 Mon Sep 17 00:00:00 2001 From: AntumDeluge Date: Sat, 27 May 2017 17:26:42 -0700 Subject: [PATCH] Set variables 'sneaker.modname' & 'sneaker.modpath' --- init.lua | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/init.lua b/init.lua index d082963..aed4d47 100644 --- a/init.lua +++ b/init.lua @@ -1,12 +1,15 @@ sneaker = {} +sneaker.modname = minetest.get_current_modname() +sneaker.modpath = minetest.get_modpath(sneaker.modname) ---[[ --- DISABLED!!! -do return end ---]] +local scripts = { + "tnt_function", + "spawn", +} -dofile(minetest.get_modpath("sneaker").."/tnt_function.lua") -dofile(minetest.get_modpath("sneaker").."/spawn.lua") +for I in pairs(scripts) do + dofile(sneaker.modpath .. "/" .. scripts[I] .. ".lua") +end local function jump(self,pos,direction) local velocity = self.object:get_velocity()