mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-10-18 19:39:20 +02:00
fix(editor): K splits the selected track where the cursor points on screen (as the hover highlight finds it), not at the delayed depth pick which hit the ground beside the rail
This commit is contained in:
@@ -5477,7 +5477,11 @@ void editor_mode::on_key(int const Key, int const Scancode, int const Action, in
|
||||
break;
|
||||
}
|
||||
if (is_press(Action) && ui()->mode() == nodebank_panel::TRACK && selected_track() != nullptr)
|
||||
split_track_at(*selected_track(), Global.pCamera.Pos + GfxRenderer->Mouse_Position());
|
||||
{
|
||||
auto const under{track_under_cursor(selected_track())};
|
||||
if (under.track != nullptr)
|
||||
split_track_at(*under.track, under.point);
|
||||
}
|
||||
break;
|
||||
|
||||
case GLFW_KEY_F:
|
||||
|
||||
Reference in New Issue
Block a user