Problem toying with infinite tech

Place to get help with not working mods / modding interface.
User avatar
Stargateur
Filter Inserter
Filter Inserter
Posts: 254
Joined: Sat Oct 05, 2019 6:17 am
Contact:

Problem toying with infinite tech

Post by Stargateur »

I would like an infinite tech to activate or desactivate "create-ghost-on-entity-death". I have fail to have the game make it infinite:

Code: Select all

  data:extend({
    {
      type = "technology",
      name = "ghost-entity-on-death-true-1",
      icon_size = 256,
      icon = "__base__/graphics/technology/construction-robotics.png",
      effects = { {
        type = "create-ghost-on-entity-death",
        modifier = true,
      } },
      unit =
      {
        count_formula = "L",
        ingredients =
        {
          { "automation-science-pack", 1 },
        },
        time = 1,
        max_level = "infinite",
      },
    },
  })
I tried several thing and nothing work. Did I do a mistake or does infinite search only work for specific effect that have modifier that is not an number ?
Natha
Filter Inserter
Filter Inserter
Posts: 260
Joined: Sun Mar 15, 2015 1:48 pm
Contact:

Re: Problem toying with infinite tech

Post by Natha »

What is the max level you get?
I just saw that max_level must not be inside unit
User avatar
Stargateur
Filter Inserter
Filter Inserter
Posts: 254
Joined: Sat Oct 05, 2019 6:17 am
Contact:

Re: Problem toying with infinite tech

Post by Stargateur »

Natha wrote: Sat May 24, 2025 1:59 pm What is the max level you get?
I just saw that max_level must not be inside unit
damm I hate lua
computeraddict
Filter Inserter
Filter Inserter
Posts: 346
Joined: Sat Oct 07, 2023 6:44 am
Contact:

Re: Problem toying with infinite tech

Post by computeraddict »

Stargateur wrote: Tue Jun 03, 2025 6:50 pm damm I hate lua
Data structure matters. You will find this everywhere you program.
User avatar
Stargateur
Filter Inserter
Filter Inserter
Posts: 254
Joined: Sat Oct 05, 2019 6:17 am
Contact:

Re: Problem toying with infinite tech

Post by Stargateur »

computeraddict wrote: Tue Jun 03, 2025 8:19 pm
Stargateur wrote: Tue Jun 03, 2025 6:50 pm damm I hate lua
Data structure matters. You will find this everywhere you program.
Yeah but a better language would have warn me... and I code since 20 years.... so..... and I'm using factorio modding tool kit and somehow it miss it anyway...
computeraddict
Filter Inserter
Filter Inserter
Posts: 346
Joined: Sat Oct 07, 2023 6:44 am
Contact:

Re: Problem toying with infinite tech

Post by computeraddict »

Stargateur wrote: Wed Jun 04, 2025 2:30 pm Yeah but a better language would have warn me... and I code since 20 years.... so..... and I'm using factorio modding tool kit and somehow it miss it anyway...
It's just the norm of dynamically typed languages. They give you a powerful tool and trust you won't point it at your own foot. People not trusting themselves with this power is how we got Typescript.
Post Reply

Return to “Modding help”