diff options
author | Stijn Buys <ingar@osirion.org> | 2008-10-16 16:34:15 +0000 |
---|---|---|
committer | Stijn Buys <ingar@osirion.org> | 2008-10-16 16:34:15 +0000 |
commit | 1a28393dabf4f4696bf433ddde52e7a25253c955 (patch) | |
tree | 4d4fa4034f30fc882a78ab6ea148a32e83b9e88c /src/client/targets.cc | |
parent | 1e0df536c2fae85c317ce9c3cc17603d5f98c911 (diff) |
various user interface related updates
Diffstat (limited to 'src/client/targets.cc')
-rw-r--r-- | src/client/targets.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/targets.cc b/src/client/targets.cc index b533974..c7fcf9e 100644 --- a/src/client/targets.cc +++ b/src/client/targets.cc @@ -413,8 +413,8 @@ void draw() x = 0; y = 0; } else { - x = (float)(input::mouse_position_x() - video::width /2) / (float)video::width; - y = (float)(input::mouse_position_y() - video::height /2) / (float)video::height / render::Camera::aspect(); + x = (float)(input::mouse_position_x() - render::Camera::width() /2) / (float)render::Camera::width(); + y = (float)(input::mouse_position_y() - render::Camera::height() /2) / (float)render::Camera::height() / render::Camera::aspect(); } Vector3f cursor = render::Camera::eye() + render::Camera::axis().forward() * (render::Camera::frustum_front() + 0.001); |