Langerz82 Posted May 13, 2017 Share Posted May 13, 2017 Hello, I got a game im extending on. I've scaled the game renderer and the HUD displayed off the screen due to the zoom so I re-positioned it. Now the mouse can only hover over the buttons when the cursor is positioned at a certain place in the worldmap. How do I correct it so the cursor can select the buttons when the cursor is correctly over them? I also note that to get the cursor to work with the scaled world I had to use massive equations which is not quite correct. See the relevant code: The offending code Link to comment Share on other sites More sharing options...
Langerz82 Posted May 13, 2017 Author Share Posted May 13, 2017 I've taken a different approach and scaling the world maps and the entities instead. I've just got to fix the mouse cursor as it targets incorrect co-ordinates. Link to comment Share on other sites More sharing options...
samme Posted May 13, 2017 Share Posted May 13, 2017 There is game.input.scale. Link to comment Share on other sites More sharing options...
Langerz82 Posted May 14, 2017 Author Share Posted May 14, 2017 Thanks samme I will keep that in mind for future reference. Link to comment Share on other sites More sharing options...
Recommended Posts