I have a script where the mouse drags an item. However, I want that script to be able to round to the nearest 10.
10 by 10: Correct
260 by 570: Correct
10 by 15: Incorrect
Here is the script:
isDragging = true
var mousePos = get_global_mouse_position()
mousePos = mousePos.floor()
What can I do to make sure it always rounds to the nearest tenth?