I have set the game to adjust the height to match the players screen. The only problem I face is that the y-position of the objects is not right. For instance:
I have a ball and a scourecounter. I have set the y-position of the scourecounter at position ball.y-360. But if the height of the screen changes, the scorecounter is not at the right place.
I want to create a variable in which the height difference between the normal game height (960px) and the changed game height is stored. Then I can set the y-position of scorecounter at position ball.y-360-variable(HeightChange). But how can I best do this?