use of on_gui_checked_state_changed ?

Place to post guides, observations, things related to modding that are not mods themselves.
User avatar
binbinhfr
Smart Inserter
Smart Inserter
Posts: 1525
Joined: Sat Feb 27, 2016 7:37 pm
Contact:

use of on_gui_checked_state_changed ?

Post by binbinhfr »

http://lua-api.factorio.com/0.13.9/even ... te_changed

about the new on_gui_checked_state_changed event, I wonder why it has been separated from on_gui_click ?
Did I miss something?

On the other hand, this new on_gui_text_changed is very useful !
My mods on the Factorio Mod Portal :geek:
User avatar
Klonan
Factorio Staff
Factorio Staff
Posts: 5341
Joined: Sun Jan 11, 2015 2:09 pm
Contact:

Re: use of on_gui_checked_state_changed ?

Post by Klonan »

binbinhfr wrote:http://lua-api.factorio.com/0.13.9/even ... te_changed

about the new on_gui_checked_state_changed event, I wonder why it has been separated from on_gui_click ?
Did I miss something?

On the other hand, this new on_gui_text_changed is very useful !

Because you can right-click a checkbox which will register the on_click but not change the state of the checkbox
User avatar
binbinhfr
Smart Inserter
Smart Inserter
Posts: 1525
Joined: Sat Feb 27, 2016 7:37 pm
Contact:

Re: use of on_gui_checked_state_changed ?

Post by binbinhfr »

Klonan wrote:Because you can right-click a checkbox which will register the on_click but not change the state of the checkbox
Oh, ok, that's subtile. I did not know that on_click was reacting to righ-clicks too. (but we cannot make the distinction with the left click, no ?)
My mods on the Factorio Mod Portal :geek:
Post Reply

Return to “Modding discussion”