I'd like to listen for click events on the player inventory GUI screen, but I have no idea how to do it. Doing: script.on_event(defines.events.on_gui_opened, FUNCTION_HERE) does not get called on any clicks.
My goal is to do this
- Open up the inventory (pressing E)
- (ctrl+shift) click on a recipe
- Do some logic + prevent crafting
Thanks