filter_slot_count error on non-inserter

Bugs that are actually features.
User avatar
binbinhfr
Smart Inserter
Smart Inserter
Posts: 1525
Joined: Sat Feb 27, 2016 7:37 pm
Contact:

filter_slot_count error on non-inserter

Post by binbinhfr »

recently you added
request_slot_count :: uint [R] The number of request slots this entity has.
this function returns 0 in case of entities which do not have/support request slots.

and also
filter_slot_count :: uint [R] The number of filter slots this inserter has.
but this variable triggers an error if it's not an inserter.
It would be nice if it returns also 0 in case of any entities that does not have/support filters, no ?
My mods on the Factorio Mod Portal :geek:
Rseding91
Factorio Staff
Factorio Staff
Posts: 15908
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: filter_slot_count error on non-inserter

Post by Rseding91 »

filter_slot_count is specific to the inserter entity - nothing else in the game ever has a non-0 filter slot count.

Also set-filter and get-filter on lua-entity only work with the inserter.

Request filters are something else completely which is why it returns 0 since multiple entities can have them.
If you want to get ahold of me I'm almost always on Discord.
Post Reply

Return to “Not a bug”