I have been searching a solution to this problem and it has started to really bother me.

I have 2 values, the objects position on y and the rotation of the object.

I want them to change in a way when the y is min the rotation is min and when the y is 1/2 the rotation is 1/2 as well.

I am not 100% sure I understand your question, but I think what you want is:

```
float y = 5; //let's say, max is 50
float rotation; //max is 360
//find percentage of y
float percent = y * 100 / 50;
rotation = 360 * (percent/100)
```