Closed Inrixia closed 5 months ago
Afik this may be a issue with the auto generated types from the Factorio docs and not this in which case there probably isnt anything you can do, but maybe someone knows who to pass this along to.
The right place to report an issue like that would be https://forums.factorio.com/viewforum.php?f=233, which is linked at the bottom of the docs website.
However, the property is marked as optional in the docs. So the type generation by the extension is the issue in this case. Looks like attributes that are marked as optional don't get that information transferred to the generated LuaLS types. Issue is not present with extension version 1.1.37, is present with 1.1.39.
That's what i get for doing a big rewrite to make use of the new stuff! This will be fixed for the next version. Seems i missed a few kinds of optionals along the way, hopefully this is the last one...
1.1.40 should fix this
The property elem_value on a LuaGuiElement can be nil if there is no selected item. To clear the selected item nil must be assigned to this property.
Currently it can only be set to
string|SignalID
as seen above. I'm bypassing the type checks atm to reset it, but figured id note it here. Afik this may be a issue with the auto generated types from the Factorio docs and not this in which case there probably isnt anything you can do, but maybe someone knows who to pass this along to.