Hello. I tried doing what you said, and using your normalize methods, and I got this
Single xpos1 = Extra.Normalize(ms.X - r.X,
(Single)Globals.WindowSize.Width,
(Single)Globals.WindowSize.Height
);
Single ypos1 = Extra.Normalize(ms.Y - r.Y,
(Single)Globals.WindowSize.Width,
(Single)Globals.WindowSize.Height
);
Single xpos2 = Extra.Denormalize(xpos1,
(Single)Globals.RenderSize.Width,
(Single)Globals.RenderSize.Height
);
Single ypos2 = Extra.Denormalize(ypos1,
(Single)Globals.RenderSize.Width,
(Single)Globals.RenderSize.Height
);
pos = new Vector2(
(xpos2 + (Globals.Camera.Position.X - (Single)(Globals.RenderSize.Width / 2))),
(ypos2 + (Globals.Camera.Position.Y - (Single)(Globals.RenderSize.Height / 2)))
);
It doesn’t seem to work, though. It also still has the issue of the real mouse moving further from the in-game mouse as it moves towards the bottom right.
I’m not sure what you mean by make the Y value Height?
I don’t think I’m properly interpreting your instructions. Is there any way you could write some pseudo-code for it?