How can I filter this article

Place to get help with not working mods / modding interface.
Post Reply
sdgmlj
Fast Inserter
Fast Inserter
Posts: 127
Joined: Sun Jul 04, 2021 11:12 pm
Contact:

How can I filter this article

Post by sdgmlj »

When I use "game.fluid_prototypes" to search all fluids, this item appears. I don't want it to be displayed. How do I filter it?

type=??
name=??
Attachments
屏幕截图 2022-06-12 195516.jpg
屏幕截图 2022-06-12 195516.jpg (35.94 KiB) Viewed 994 times

User avatar
DaveMcW
Smart Inserter
Smart Inserter
Posts: 3700
Joined: Tue May 13, 2014 11:06 am
Contact:

Re: How can I filter this article

Post by DaveMcW »

Code: Select all

for _, fluid in pairs(game.fluid_prototypes) do
  if not fluid.hidden then
    game.print(fluid.name)
  end
end

sdgmlj
Fast Inserter
Fast Inserter
Posts: 127
Joined: Sun Jul 04, 2021 11:12 pm
Contact:

Re: How can I filter this article

Post by sdgmlj »

DaveMcW wrote:
Sun Jun 12, 2022 4:30 pm

Code: Select all

for _, fluid in pairs(game.fluid_prototypes) do
  if not fluid.hidden then
    game.print(fluid.name)
  end
end
Thank you, that's right

Post Reply

Return to “Modding help”