From 5e95f2088999f38873458414fafe2c41448abf32 Mon Sep 17 00:00:00 2001 From: Harrison Deng Date: Fri, 7 May 2021 16:44:58 -0500 Subject: [PATCH] Changed to floor instead of string. --- mineleader.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mineleader.lua b/mineleader.lua index b02bdfc..45d39e6 100644 --- a/mineleader.lua +++ b/mineleader.lua @@ -366,7 +366,7 @@ local function moveBy(delta, forward, right) end local function moveTo(dest) - dest = vector.new(tonumber(string.format("%.0f", dest.x)), tonumber(string.format("%.0f", dest.y)), tonumber(string.format("%.0f", dest.z))) + dest = vector.new(math.floor(dest.x), math.floor(dest.y), math.floor(dest.z)) sendLog(MOVETO, "Attempting to move by (" .. dest.x .. "," .. dest.y .. "," .. dest.z .. ") (x,y,z).") if position == nil or heading == nil then sendLog(FAILED, "Position or heading is invalid.")