Page 1 of 1
[2.0.6] Wrong modding documentation for LuaLogisticPoint.filters
Posted: Sun Oct 20, 2024 10:09 pm
by micromario
The docs define a flat struct for `LuaLogisticPoint.filters`

- 10-20-2024, 17-09-02.png (49.01 KiB) Viewed 287 times
However testing in-game reveals there is actually a nested value={} struct.

- 10-20-2024, 17-09-52.png (698.86 KiB) Viewed 287 times
Re: [2.0.6] Wrong modding documentation for LuaLogisticPoint.filters
Posted: Mon Oct 21, 2024 7:30 am
by boskid
I am going to call this Not a bug because you are showing CompiledLogisticFilter docs which is used by LuaLogisticPoint::filters, however the data you are showing is clearly coming from a different structure, possibly LuaLogisticSection::filters which uses LogisticFilter.
LuaLogisticPoint::filters returns array of CompiledLogisticFilter which should not contain empty items (instead there will be discontinuity on the `index` field. This data is going internally through a PropertyTree which is unable to give anything more advanced than numbers, strings and nested tables and yet in your case there is `import_from` present which contains LuaSpaceLocationPrototype (lua object). On top of this there is no index and there was an empty item at [1] given. Given the presence of `import_from` (which is only used on the LogisticFilters as it is the source data used by logistic filters) it is almost guaranteed you are simply looking at wrong docs which makes this not a bug.