TL:DR The output type of LuaBootstrap::generate_event_name can not be given as input to LuaBootstrap::raise_event.
The return type of LuaBootstrap::generate_event_name is "defines.events"
The input type of LuaBootstrap::raise_event is "uint or string"
This works at runtime but the types are not soundly defined, and so is a documentation issue.
I would suggest using "LuaEventType" which is used as the input for LuaBootstrap::on_event
[2.0.28] Type mismatch between generate_event_name and raise_event
- Cooldude2606
- Fast Inserter
- Posts: 108
- Joined: Sat Sep 16, 2017 9:04 pm
- Contact:
[2.0.28] Type mismatch between generate_event_name and raise_event
Last edited by Cooldude2606 on Fri Jan 10, 2025 5:56 pm, edited 1 time in total.
- Cooldude2606
- Fast Inserter
- Posts: 108
- Joined: Sat Sep 16, 2017 9:04 pm
- Contact:
Re: [2.0.28] Type mismatch between generate_event_name and raise_event
The suggested change was implemented in 2.0.29