From 98231f15ae27d661239ee40a70cf7c225e21c422 Mon Sep 17 00:00:00 2001 From: cora Date: Thu, 19 May 2022 00:50:46 +0200 Subject: [PATCH] change function name go_wplist -> gopath --- mods/ENTITIES/mcl_mobs/api.lua | 2 +- mods/ENTITIES/mobs_mc/villager.lua | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/mods/ENTITIES/mcl_mobs/api.lua b/mods/ENTITIES/mcl_mobs/api.lua index 5a4873438..71fa681e3 100644 --- a/mods/ENTITIES/mcl_mobs/api.lua +++ b/mods/ENTITIES/mcl_mobs/api.lua @@ -2919,7 +2919,7 @@ local do_states = function(self, dtime) end end -function mobs:go_wplist(self,target,callback_arrived) +function mobs:gopath(self,target,callback_arrived) local p = self.object:get_pos() local t = vector.offset(target,0,1,0) if not target or not p then return end diff --git a/mods/ENTITIES/mobs_mc/villager.lua b/mods/ENTITIES/mobs_mc/villager.lua index 334bed23f..e96cd99b4 100644 --- a/mods/ENTITIES/mobs_mc/villager.lua +++ b/mods/ENTITIES/mobs_mc/villager.lua @@ -575,7 +575,7 @@ local function go_home(entity) entity.state = "go_home" local b=entity.bed if not b then return end - mobs:go_wplist(entity,b,function(entity,b) + mobs:gopath(entity,b,function(entity,b) if vector.distance(entity.object:get_pos(),b) < 2 then entity.state = "stand" set_velocity(entity,0) @@ -618,7 +618,7 @@ local function look_for_job(self) if m:get_string("villager") == "" then --minetest.log("goingt to jobsite "..minetest.pos_to_string(n) ) minetest.after(0,function() - mobs:go_wplist(self,n,function() + mobs:gopath(self,n,function() --minetest.log("arrived jobsite "..minetest.pos_to_string(n) ) end) end) @@ -1242,7 +1242,7 @@ mobs:register_mob("mobs_mc:villager", { on_rightclick = function(self, clicker) local trg=vector.new(0,9,0) if self._jobsite then - mobs:go_wplist(self,self._jobsite,function() + mobs:gopath(self,self._jobsite,function() --minetest.log("arrived at jobsite") end) end