Fractal Softworks Forum

Please login or register.

Login with username, password and session length

Author Topic: Help needed  (Read 3035 times)

Miter

  • Ensign
  • *
  • Posts: 13
    • View Profile
Help needed
« on: July 21, 2012, 12:44:23 AM »

I tried to add a weapon to the game (nothing special, just bigger Gauss Cannon). I did everything needed for this weapon to work, but when I try to  start Starfarer it gives me an error message: "Fatal: JSONObiect["id"] not found".

Log:
Spoiler
3422 [Thread-6] INFO  com.fs.starfarer.loading.WeaponSpecLoader  - Loading weapon [C:\Program Files\Fractal Softworks\Starfarer\starfarer-core\data\weapons\vulcan.wpn]
3423 [Thread-6] INFO  com.fs.starfarer.loading.LoadingUtils  - Loading JSON from [C:\Program Files\Fractal Softworks\Starfarer\starfarer-core\data\weapons\vulcan.wpn]
3427 [Thread-6] INFO  com.fs.starfarer.loading.LoadingUtils  - Loading CSV data from [ABSOLUTE_AND_CWD: null]
3542 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.scripts.plugins.BattleObjectivesFleetPointsPluginImpl]
3563 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.scripts.plugins.BattleObjectivesFogOfWarPluginImpl]
3589 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.scripts.world.BaseSpawnPoint]
3621 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.scripts.world.SectorGen]
3743 [Thread-6] INFO  com.fs.profiler.Profiler  - ID     Calls   Duration    Percent
3751 [Thread-6] INFO  com.fs.profiler.Profiler  - --------------------------------
3753 [Thread-6] ERROR com.fs.starfarer.combat.D  - org.json.JSONException: JSONObject["id"] not found.
org.json.JSONException: JSONObject["id"] not found.
   at org.json.JSONObject.get(JSONObject.java:406)
   at org.json.JSONObject.getString(JSONObject.java:577)
   at com.fs.starfarer.loading.LoadingUtils.o00000(Unknown Source)
   at com.fs.starfarer.loading.LoadingUtils.o00000(Unknown Source)
   at com.fs.starfarer.loading.WeaponSpreadsheetLoader.?00000(Unknown Source)
   at com.fs.starfarer.loading.SpecStore.o00000(Unknown Source)
   at com.fs.starfarer.loading.G.o00000(Unknown Source)
   at com.fs.oOOO.A.?00000(Unknown Source)
   at com.fs.starfarer.combat.D.o00000(Unknown Source)
   at com.fs.starfarer.StarfarerLauncher$2.run(Unknown Source)
   at java.lang.Thread.run(Thread.java:619)
3761 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.missions.turningthetables.MissionDefinition]
3823 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.missions.forthegreaterlud.MissionDefinition]
[close]

Anyone knows how to fix this?
Logged

Sproginator

  • Admiral
  • *****
  • Posts: 3592
  • Forum Ancient
    • View Profile
Re: Help needed
« Reply #1 on: July 21, 2012, 11:19:53 AM »

I tried to add a weapon to the game (nothing special, just bigger Gauss Cannon). I did everything needed for this weapon to work, but when I try to  start Starfarer it gives me an error message: "Fatal: JSONObiect["id"] not found".

Log:
Spoiler
3422 [Thread-6] INFO  com.fs.starfarer.loading.WeaponSpecLoader  - Loading weapon [C:\Program Files\Fractal Softworks\Starfarer\starfarer-core\data\weapons\vulcan.wpn]
3423 [Thread-6] INFO  com.fs.starfarer.loading.LoadingUtils  - Loading JSON from [C:\Program Files\Fractal Softworks\Starfarer\starfarer-core\data\weapons\vulcan.wpn]
3427 [Thread-6] INFO  com.fs.starfarer.loading.LoadingUtils  - Loading CSV data from [ABSOLUTE_AND_CWD: null]
3542 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.scripts.plugins.BattleObjectivesFleetPointsPluginImpl]
3563 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.scripts.plugins.BattleObjectivesFogOfWarPluginImpl]
3589 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.scripts.world.BaseSpawnPoint]
3621 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.scripts.world.SectorGen]
3743 [Thread-6] INFO  com.fs.profiler.Profiler  - ID     Calls   Duration    Percent
3751 [Thread-6] INFO  com.fs.profiler.Profiler  - --------------------------------
3753 [Thread-6] ERROR com.fs.starfarer.combat.D  - org.json.JSONException: JSONObject["id"] not found.
org.json.JSONException: JSONObject["id"] not found.
   at org.json.JSONObject.get(JSONObject.java:406)
   at org.json.JSONObject.getString(JSONObject.java:577)
   at com.fs.starfarer.loading.LoadingUtils.o00000(Unknown Source)
   at com.fs.starfarer.loading.LoadingUtils.o00000(Unknown Source)
   at com.fs.starfarer.loading.WeaponSpreadsheetLoader.?00000(Unknown Source)
   at com.fs.starfarer.loading.SpecStore.o00000(Unknown Source)
   at com.fs.starfarer.loading.G.o00000(Unknown Source)
   at com.fs.oOOO.A.?00000(Unknown Source)
   at com.fs.starfarer.combat.D.o00000(Unknown Source)
   at com.fs.starfarer.StarfarerLauncher$2.run(Unknown Source)
   at java.lang.Thread.run(Thread.java:619)
3761 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.missions.turningthetables.MissionDefinition]
3823 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.missions.forthegreaterlud.MissionDefinition]
[close]

Anyone knows how to fix this?

Your game is trying to load a weapon from an ID that doesn't exist, i think.

Simply look over all the names defined in each file. and also make sure the file name itself is correct :)
Logged
A person who's never made a mistake, never tried anything new
- Albert Einstein

As long as we don't quit, we haven't failed
- Jamie Fristrom (Programmer for Spiderman2 & Lead Developer for Energy Hook)

Miter

  • Ensign
  • *
  • Posts: 13
    • View Profile
Re: Help needed
« Reply #2 on: July 22, 2012, 05:26:23 AM »

I checked all the ids like 10 times, but i can't find anything wrong.
I deleted my weapon from weapon_data, but I still get the error.
Logged

Strifen

  • Commander
  • ***
  • Posts: 117
    • View Profile
Re: Help needed
« Reply #3 on: July 22, 2012, 06:53:55 AM »

  Did you try adding the weapon through 'mods' or into the 'starfarer-core'?
this:
I checked all the ids like 10 times, but i can't find anything wrong.
I deleted my weapon from weapon_data, but I still get the error.
is what's troubling me in that regard; if it was through the mod loader, it shouldn't be causing the error in the vanilla/core game.

  though looking at the .log you posted, the first thing I'd look at would be mission data...
but then again, I haven't had much modding experience.
« Last Edit: July 22, 2012, 06:55:52 AM by Strifen »
Logged

Miter

  • Ensign
  • *
  • Posts: 13
    • View Profile
Re: Help needed
« Reply #4 on: July 22, 2012, 10:24:22 AM »

At first, I added it to starfarer-core, but now I made a mod out of it, and it's working.:)
Logged

Sproginator

  • Admiral
  • *****
  • Posts: 3592
  • Forum Ancient
    • View Profile
Re: Help needed
« Reply #5 on: July 22, 2012, 02:59:21 PM »

At first, I added it to starfarer-core, but now I made a mod out of it, and it's working.:)
Adding it to the core almost never works
Logged
A person who's never made a mistake, never tried anything new
- Albert Einstein

As long as we don't quit, we haven't failed
- Jamie Fristrom (Programmer for Spiderman2 & Lead Developer for Energy Hook)

Miter

  • Ensign
  • *
  • Posts: 13
    • View Profile
Re: Help needed
« Reply #6 on: July 27, 2012, 02:12:52 AM »

Another error:
Fatal: null
Log:
Spoiler
4991 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.missions.turningthetables.MissionDefinition]
5042 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.missions.forthegreaterlud.MissionDefinition]
5099 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.missions.thewolfpack.MissionDefinition]
5101 [Thread-6] INFO  com.fs.profiler.Profiler  - ID     Calls   Duration    Percent
5103 [Thread-6] INFO  com.fs.profiler.Profiler  - --------------------------------
5106 [Thread-6] ERROR com.fs.starfarer.combat.D  - java.lang.NullPointerException
java.lang.NullPointerException
   at com.fs.starfarer.loading.specs.Z.o00000(Unknown Source)
   at com.fs.starfarer.loading.WeaponSpecLoader.new(Unknown Source)
   at com.fs.starfarer.loading.WeaponSpecLoader.new(Unknown Source)
   at com.fs.starfarer.loading.SpecStore.o00000(Unknown Source)
   at com.fs.starfarer.loading.G.o00000(Unknown Source)
   at com.fs.oOOO.A.?00000(Unknown Source)
   at com.fs.starfarer.combat.D.o00000(Unknown Source)
   at com.fs.starfarer.StarfarerLauncher$2.run(Unknown Source)
   at java.lang.Thread.run(Thread.java:619)
5172 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.missions.hornetsnest.MissionDefinition]
5227 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.missions.thelasthurrah.MissionDefinition]
5297 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.missions.direstraits.MissionDefinition]
[close]
I tried to add another weapon to my mod, and I started to get this error. Im sure it's not about wrong ids. It seems to be something with missions, but I didn't change anything in there.
Logged

Sproginator

  • Admiral
  • *****
  • Posts: 3592
  • Forum Ancient
    • View Profile
Re: Help needed
« Reply #7 on: July 27, 2012, 05:23:11 AM »

Another error:
Fatal: null
Log:
Spoiler
4991 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.missions.turningthetables.MissionDefinition]
5042 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.missions.forthegreaterlud.MissionDefinition]
5099 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.missions.thewolfpack.MissionDefinition]
5101 [Thread-6] INFO  com.fs.profiler.Profiler  - ID     Calls   Duration    Percent
5103 [Thread-6] INFO  com.fs.profiler.Profiler  - --------------------------------
5106 [Thread-6] ERROR com.fs.starfarer.combat.D  - java.lang.NullPointerException
java.lang.NullPointerException
   at com.fs.starfarer.loading.specs.Z.o00000(Unknown Source)
   at com.fs.starfarer.loading.WeaponSpecLoader.new(Unknown Source)
   at com.fs.starfarer.loading.WeaponSpecLoader.new(Unknown Source)
   at com.fs.starfarer.loading.SpecStore.o00000(Unknown Source)
   at com.fs.starfarer.loading.G.o00000(Unknown Source)
   at com.fs.oOOO.A.?00000(Unknown Source)
   at com.fs.starfarer.combat.D.o00000(Unknown Source)
   at com.fs.starfarer.StarfarerLauncher$2.run(Unknown Source)
   at java.lang.Thread.run(Thread.java:619)
5172 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.missions.hornetsnest.MissionDefinition]
5227 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.missions.thelasthurrah.MissionDefinition]
5297 [Thread-10] INFO  com.fs.starfarer.loading.scripts.ScriptStore  - Compiling script [data.missions.direstraits.MissionDefinition]
[close]
I tried to add another weapon to my mod, and I started to get this error. Im sure it's not about wrong ids. It seems to be something with missions, but I didn't change anything in there.
Right, Add me on steam a sec, Sproginator66, And upload the work you have done so far, As far as i can see from now, Your using the wrong ID for something, I think, add me all the same

Edit:

The reason i think it is the wrong ID's is from:
 at com.fs.starfarer.loading.specs.Z.o00000(Unknown Source)
   at com.fs.starfarer.loading.WeaponSpecLoader.new(Unknown Source)
   at com.fs.starfarer.loading.WeaponSpecLoader.new(Unknown Source)
   at com.fs.starfarer.loading.SpecStore.o00000(Unknown Source)
   at com.fs.starfarer.loading.G.o00000(Unknown Source)
   at com.fs.oOOO.A.?00000(Unknown Source)
   at com.fs.starfarer.combat.D.o00000(Unknown Source)
   at com.fs.starfarer.StarfarerLauncher$2.run(Unknown Source)

It may be the CSV file for the weapon stats that it is unable to get, i think
Logged
A person who's never made a mistake, never tried anything new
- Albert Einstein

As long as we don't quit, we haven't failed
- Jamie Fristrom (Programmer for Spiderman2 & Lead Developer for Energy Hook)