Page 1 of 1

General confirm event?

Posted: Thu Apr 15, 2021 7:33 pm
by hoylemd
in FFF#362 https://factorio.com/blog/post/fff-362 it's mentioned that the `E` hotkey has been redefined to mean 'confirm' instead of `cancel` which is bound by default to `Esc`. I'm working on a mod where there's a pop-up gui, and I'd like it to respect this convention. I've got it handling `on_gui_closed` properly, but it seems that the `E` hotkey triggers that event, not `on_gui_confirmed` (which appears only to be fired by pressing enter in a text box?). Am I missing something in the docs about properly registering for a confirm event, or is this priviledged functionality to the core game?

Re: General confirm event?

Posted: Sat Apr 24, 2021 10:02 am
by eradicator
I'd go with a custom input with linked_game_control = 'confirm-gui'.