only write coordinates on button press, and not again on release
This commit is contained in:
parent
f9bf9fd073
commit
38d44f2c01
1 changed files with 1 additions and 1 deletions
|
@ -319,7 +319,7 @@ FGInput::doMouseClick (int b, int updown, int x, int y)
|
||||||
// and be happy.
|
// and be happy.
|
||||||
FGScenery* scenery = globals->get_scenery();
|
FGScenery* scenery = globals->get_scenery();
|
||||||
sgdVec3 start, dir, hit;
|
sgdVec3 start, dir, hit;
|
||||||
if (FGRenderer::getPickInfo(start, dir, x, y) &&
|
if (updown && FGRenderer::getPickInfo(start, dir, x, y) &&
|
||||||
scenery->get_cart_ground_intersection(start, dir, hit)) {
|
scenery->get_cart_ground_intersection(start, dir, hit)) {
|
||||||
|
|
||||||
Point3D geod = sgCartToGeod(Point3D(hit[0], hit[1], hit[2]));
|
Point3D geod = sgCartToGeod(Point3D(hit[0], hit[1], hit[2]));
|
||||||
|
|
Loading…
Add table
Reference in a new issue