Page 1 of 1

LuaEntity.result_quality type is inconsistent with description

Posted: Mon Oct 21, 2024 2:17 pm
by curiosity
https://lua-api.factorio.com/latest/cla ... lt_quality

The description says the property may be nil, but may not be set to nil. Meanwhile, the declaration says it always reads as LuaQualityPrototype, but accepts QualityID or nil. Seems like you misplaced the question mark.

Re: LuaEntity.result_quality type is inconsistent with description

Posted: Mon Oct 21, 2024 3:13 pm
by Therenas
This is a bit awkward: The optionality applies to both read and write types, even though it might not look like it. This is something to be improved in the future.

In the meantime, I made it so the questionmark isn't directly attached to the write type, and made the description a bit less confusing for the next release.