Skip to content

Gui events not working #160

@lukas-gerster

Description

@lukas-gerster

Describe the Bug

The Gui.on_click and similar events do not seem to be functional

To Reproduce

Steps to reproduce the behavior:

--Gui.on_click("ii-close-button", function(e) window.close(e.player_index) end) Event.register(defines.events.on_gui_click, function(e) window.close(e.player_index) end, function(e) return e.element.name == "ii-close-button" end)
These two functions are expected to show the same behaviour, calling window.close when the button is clicked, but using the first handler is not working, while manually registering the event works.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions