From b3e1df7e9b374bde37492a72c23ee9b4efe5a8c3 Mon Sep 17 00:00:00 2001 From: Wuzzy Date: Wed, 2 Oct 2019 21:18:29 +0200 Subject: [PATCH] Round pos in spawnstruct chatcommand --- mods/MAPGEN/mcl_structures/init.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/mods/MAPGEN/mcl_structures/init.lua b/mods/MAPGEN/mcl_structures/init.lua index 26fd7b2cc3..132c708960 100644 --- a/mods/MAPGEN/mcl_structures/init.lua +++ b/mods/MAPGEN/mcl_structures/init.lua @@ -463,10 +463,11 @@ minetest.register_chatcommand("spawnstruct", { description = S("Generate a pre-defined structure near your position."), privs = {debug = true}, func = function(name, param) - local pos= minetest.get_player_by_name(name):get_pos() + local pos = minetest.get_player_by_name(name):get_pos() if not pos then return end + pos = vector.round(pos) local errord = false local message = S("Structure placed.") if param == "village" then