Why this entity isnt beeing loaded correctly?

Place to get help with not working mods / modding interface.
ficolas
Smart Inserter
Smart Inserter
Posts: 1068
Joined: Sun Feb 24, 2013 10:24 am
Contact:

Why this entity isnt beeing loaded correctly?

Post by ficolas »

Code: Select all

data:extend(
  {
    type = "explosion",
    name = "alien-artifact-pickup",
    animation_speed = 5,
    animations =
    {
      {
        filename = "__F-mod__/resources/particles/alien-artifact-pickup.png",
        priority = "extra-high",
        frame_width = 32,
        frame_height = 32,
        frame_count = 8,
        line_length = 8
      }
    },
    light = {intensity = 0, size = 0},
    smoke = "smoke",
    smoke_count = 5,
    smoke_slow_down_factor = 1,
    sound =
    {
      {
        filename = "__base__/sound/huge-explosion.wav",
        volume = 0
      }
    }
  })
Im sure the game is loading it, because if I write some error there like writing ((, the game sends an error, but when I try to create an alien-artifact-pickup entity, ( game.createentity({name="alien-artifact-pickup",position=game.player.character.position})), it says that alien-artifact-pickup is an unknown entity name
User avatar
rk84
Filter Inserter
Filter Inserter
Posts: 556
Joined: Wed Feb 13, 2013 9:15 am
Contact:

Re: Why this entity isnt beeing loaded correctly?

Post by rk84 »

Does the mod's folder name and name inside info file match?
Test mode
Searching Flashlight
[WIP]Fluid handling expansion
[WIP]PvP gamescript
[WIP]Rocket Express
Autofill: The torch has been pass to Nexela
ficolas
Smart Inserter
Smart Inserter
Posts: 1068
Joined: Sun Feb 24, 2013 10:24 am
Contact:

Re: Why this entity isnt beeing loaded correctly?

Post by ficolas »

rk84 wrote:Does the mod's folder name and name inside info file match?
yup didnt change it and other entities are beeing loaded just fine.
User avatar
rk84
Filter Inserter
Filter Inserter
Posts: 556
Joined: Wed Feb 13, 2013 9:15 am
Contact:

Re: Why this entity isnt beeing loaded correctly?

Post by rk84 »

Oh could it be that you are missing one set of curly brackets around that entity definition?
Test mode
Searching Flashlight
[WIP]Fluid handling expansion
[WIP]PvP gamescript
[WIP]Rocket Express
Autofill: The torch has been pass to Nexela
ficolas
Smart Inserter
Smart Inserter
Posts: 1068
Joined: Sun Feb 24, 2013 10:24 am
Contact:

Re: Why this entity isnt beeing loaded correctly?

Post by ficolas »

rk84 wrote:Oh could it be that you are missing one set of curly brackets around that entity definition?
there are no curly brackets missing, and if there where, it would send an error msg
User avatar
rk84
Filter Inserter
Filter Inserter
Posts: 556
Joined: Wed Feb 13, 2013 9:15 am
Contact:

Re: Why this entity isnt beeing loaded correctly?

Post by rk84 »

ficolas wrote:
rk84 wrote:Oh could it be that you are missing one set of curly brackets around that entity definition?
there are no curly brackets missing, and if there where, it would send an error msg
I can't remember for sure what was in dataloader.lua, but I think extend() expect to get array of tables. So there is no error message, because it treat it like empty table and skips it.
Test mode
Searching Flashlight
[WIP]Fluid handling expansion
[WIP]PvP gamescript
[WIP]Rocket Express
Autofill: The torch has been pass to Nexela
slpwnd
Factorio Staff
Factorio Staff
Posts: 1835
Joined: Sun Feb 03, 2013 2:51 pm
Contact:

Re: Why this entity isnt beeing loaded correctly?

Post by slpwnd »

rk84 wrote:
ficolas wrote:
rk84 wrote:Oh could it be that you are missing one set of curly brackets around that entity definition?
there are no curly brackets missing, and if there where, it would send an error msg
I can't remember for sure what was in dataloader.lua, but I think extend() expect to get array of tables. So there is no error message, because it treat it like empty table and skips it.
Yes, I would expect that to be the issue here.
Post Reply

Return to “Modding help”