Fix warnings about deprecated methods

This commit is contained in:
bri cassa 2021-03-27 22:56:43 +01:00
parent f83705bb6c
commit 453b6c7400
1 changed files with 3 additions and 3 deletions

View File

@ -242,13 +242,13 @@ do -- register a definition of an egg entity
})
self.object:setpos(new_position)
else
local cur_position = self.object:getpos()
local cur_position = self.object:get_pos()
local new_position = {
x = cur_position.x,
y = self.center_position.y + math.sin(self.angle * math.pi / 180.0) * 0.025,
z = cur_position.z,
}
self.object:setpos(new_position)
self.object:set_pos(new_position)
end
end
@ -256,7 +256,7 @@ do -- register a definition of an egg entity
self.angle = 0
self.center_position = pos
local init_pos = vector.add(pos, {x = 0.15, y = 0, z = 0})
self.object:setpos(init_pos)
self.object:set_pos(init_pos)
end
minetest.register_entity("maidroid_tool:egg_entity", {