diff options
author | Anilforextra <anilforextra@gmail.com> | 2021-09-25 14:46:45 +0545 |
---|---|---|
committer | Anilforextra <anilforextra@gmail.com> | 2021-09-25 14:46:45 +0545 |
commit | cdd912c48eab15f581459afc2cda8fdcfabf92db (patch) | |
tree | d2d4ce59b2e55c8947103fc40ce1258728a8dc65 /tests | |
parent | 5e4a71200e25811d8e570d87f08f0878dabb8bb9 (diff) |
Construct values only when necessary.
Diffstat (limited to 'tests')
-rw-r--r-- | tests/test_physics_2d.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/test_physics_2d.cpp b/tests/test_physics_2d.cpp index f63b866c3e..f6619db8fd 100644 --- a/tests/test_physics_2d.cpp +++ b/tests/test_physics_2d.cpp @@ -199,7 +199,7 @@ protected: if (mb.is_valid()) { if (mb->is_pressed()) { - Point2 p(mb->get_position().x, mb->get_position().y); + Point2 p = mb->get_position(); if (mb->get_button_index() == 1) { ray_to = p; |