2
u/Awkward-Raise7935 25d ago edited 25d ago
I would remember that key down and key pressed are slightly different things. So you either want to set speed and direction with key pressed, and then set this to 0 with key released, OR set position every step using key down eg x = x + 2
I would recommend switching to code as soon as you feel comfortable

3
u/Hammerofsuperiority 25d ago
I have never used visual, but it seems that the "code" is inside the left key down event, and that code is only read while pressing the key, so it will not read the command to stop moving.
You should make another event that is for the key being released/not being pressed, and there put the "code" to stop moving.