Hi!
I hope I explain myself well enough.
I'm making a side-scrolling minigolf game. I used the catapult code as an example to make a little "puncher" that can only separate from the ball a certain distance, like the pig from the example does with the top of the catapult. Now I can easily make an impulse based on that distance, so I can control the limit by dividing it or whatever.
But I'd like this maximum distance that goes from 0 to, let's say, 25,3 (in pixels) to show as 10 in a textbox. So no matter the real value it's working behind the scenes, I want the max distance to be represented as 10 (you now, something rounder, 0 to 10 in power). Or 100, or whatever the number I like.
Some help with the formula? I'm terrible at math :(