testing a little visualizer thing, this works as intended when divisor is a high value (first image), however with a low divisor (this means it'll be hitting it's maximum, or at least near maximum) the offset seems to freak out a little bit and go above where it should (second image). Any ideas why this happens/how I could try to fix it? Thanks!

            elseif visType == "headstretch" then
                local yScale = math.clamp(loudness / divisor + originalSizeHead.Y, originalSizeHead.Y, 5.564)
                player.Character.Head.Mesh.Scale = Vector3.new(originalSizeHead.X, yScale, originalSizeHead.Z)
                player.Character.Head.Mesh.Offset = Vector3.new(0, math.abs(math.clamp(loudness / divisor / 2, 0, 5.564)), 0)

First image, intended functionality

second image, unintended functionality

also, a couple notes:

  • 5.564 is the highest I could find the head mesh scaling to (on the Y axis at least) before the texture starts to display improperly, that is why it's the maximum

  • I'm setting the offset in the first place to produce the illusion of the head only going up instead of both directions

EDIT: Alright well I'm a bit of an idiot. The maximum on the offset was 5.564, however the offset should only ever be ~half of that.