From 72e5fbb6fe58166278f1b356e7d52d573d34034e Mon Sep 17 00:00:00 2001 From: richard <56808540+littensy@users.noreply.github.com> Date: Mon, 19 Aug 2024 06:56:00 -0700 Subject: [PATCH] Round UDim offset values (#30) --- src/spring.luau | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/spring.luau b/src/spring.luau index 9e4f48a..bd1a990 100644 --- a/src/spring.luau +++ b/src/spring.luau @@ -114,11 +114,11 @@ local vec6_to_type = { end :: Vec6ToType, UDim = function(v) - return UDim.new(v.X, v.Y) + return UDim.new(v.X, math.round(v.Y)) end :: Vec6ToType, UDim2 = function(a, b) - return UDim2.new(a.X, a.Y, a.Z, b.X) + return UDim2.new(a.X, math.round(a.Y), a.Z, math.round(b.X)) end :: Vec6ToType, Vector2 = function(v)