assume you want to select an autonomous before connecting to field control, however, that loop is registering the ButtonLeft.pressed and ButtonA.pressed events many times. You must only register event handlers once.
also
Controller1.ButtonLeft.pressed([]() -> void {});
you cannot unregister an event handler unless you stop all tasks when the robot becomes disabled by setting bStopAllTasksBetweenModes to true.
see this post, make necessary changes and then see what happens.