20157 Posts in 3360 Topics - by 6693 Members - Latest Member: Awes597

Author Topic: Founding mines - Entity exists already  (Read 101 times)

Hammelpilaw

  • Full Member
  • ***
  • Posts: 107
    • View Profile
Founding mines - Entity exists already
« on: August 08, 2017, 01:25:03 PM »
We have a problem on our server while founding mines from claimable asteroids:

Code: [Select]
2017-08-07 12-39-39| could not execute function 'foundFactory' in '"data/scripts/entity/minefounder.lua"':
2017-08-07 12-39-39| Entity exists already
2017-08-07 12-39-39| [C]:-1: in function createEntity
2017-08-07 12-39-39| data/scripts/entity/minefounder.lua:285: in function transformToStation
2017-08-07 12-39-39| data/scripts/entity/minefounder.lua:252: in function ?
2017-08-07 12-39-39| Setting state to invalid.
2017-08-07 12-39-43| An error occurred during remote call to 'foundFactory' in script "data/scripts/entity/minefounder.lua". Function doesn't exist.

When this happens the claimable asteroid does not despawn, but most times the claimed mine spawns anywhere in the sector with strange plans loaded, wich already exist on other player mines. For example this one:



The huge stone block looks like a mine wich already exists in the galaxy (sadly we do not know wich one exactly), the small cargo blocks wich looks like what a founded station adds to a founding ship are automaticly added. This was generated when I founded the mine, I did not modify it... and it caused the error log above.


Could this be caused by loading ship plans on founded mines?

Daemon

  • Newbie
  • *
  • Posts: 22
    • View Profile
Re: Founding mines - Entity exists already
« Reply #1 on: August 08, 2017, 01:28:01 PM »
Do you have any mod? It seems like the script file is missing a function but I just checked the original avorion files and it's there:
function foundFactory(goodName, productionIndex)

Hammelpilaw

  • Full Member
  • ***
  • Posts: 107
    • View Profile
Re: Founding mines - Entity exists already
« Reply #2 on: August 08, 2017, 01:47:01 PM »
We use a lot of mods, but the scripts itself does not seem to be the problem. The scripts itself works.

Code: [Select]
2017-08-07 12-39-39| Entity exists already
I think there should be a problem with entities... we just backed up the galaxy and started to destroy and delete some of the existing player mines, now it works fine again. But this was not the first time that this error accured... the last time there was only one player mine wich needed to be completely deleted to make everything work fine again.

Hammelpilaw

  • Full Member
  • ***
  • Posts: 107
    • View Profile
Re: Founding mines - Entity exists already
« Reply #3 on: August 08, 2017, 02:45:04 PM »
Just did some testing:
The problem seems to happen, when you found two mines of the same type, like two copper mines. The first one works fine, the 2nd one gets bugged.
I reproduced this in a vanilla offline game, in a new galaxy (ok I used the Avorion command package to spawn some equipment for finding asteroids, but this should not cause these issues). So to me it looks like an avorion bug.

Hammelpilaw

  • Full Member
  • ***
  • Posts: 107
    • View Profile
Re: Founding mines - Entity exists already
« Reply #4 on: August 10, 2017, 11:35:01 AM »
Finally i completely uninstalled Avorion, deleted all config and user-data and tried again with a new installed game: It is still the same, I can't imagine that I am the only one with this problem. Can anybody confirm if it works or not?

Devious

  • Sr. Member
  • ****
  • Posts: 428
    • View Profile
    • Rusty's Galaxies and Community
Re: Founding mines - Entity exists already
« Reply #5 on: August 10, 2017, 12:19:26 PM »
Can confirm this issue, we haven't find out the cause yet as we have a lot of mods aswell.
The only one that directly involves claimable asteroids is MineCorp, but there doesn't seem to be an issue with that.

This isn't the first time the engine has issues with duplicate entities so my bet is that it's a vanilla bug.

Hammelpilaw

  • Full Member
  • ***
  • Posts: 107
    • View Profile
Re: Founding mines - Entity exists already
« Reply #6 on: August 10, 2017, 12:26:27 PM »
Can confirm this issue, we haven't find out the cause yet as we have a lot of mods aswell.
The only one that directly involves claimable asteroids is MineCorp, but there doesn't seem to be an issue with that.

This isn't the first time the engine has issues with duplicate entities so my bet is that it's a vanilla bug.

It is definitely not caused by a mod, because i get this issue also in a new generated vanilla galaxy. MineCorp should not touch claimable asteroids... but even if it does, the mod works fine. So if I am not the only one this must be an Avorion bug. Lets hope for a fix soon.

Devious

  • Sr. Member
  • ****
  • Posts: 428
    • View Profile
    • Rusty's Galaxies and Community
Re: Founding mines - Entity exists already
« Reply #7 on: August 12, 2017, 04:44:07 PM »
Just replicated this issue on vanilla, here are the steps:

- Build a mine on a claimable asteroid, doesn't matter which type.
- Build the same type of mine in the same sector or elsewhere, doesn't matter.
- When acknowledging the warning screen of the second mine it draws the money but doesn't build the mine.
- When you jump out of the sector and back in, the old asteroid is still at its original position but in the center of the sector a glitched mine will spawn of the type you purchased, without any functionality besides being able to hire crew there.

Here is a screenshot of the associated error: