[Mod\Fix] Fix ships not being returned at Chapter 2 end

The place to discuss scripting and game modifications for X Rebirth.

Moderators: Scripting / Modding Moderators, Moderators for English X Forum

Ndyil
Posts: 44
Joined: Sat, 23. Nov 13, 04:57

[Mod\Fix] Fix ships not being returned at Chapter 2 end

Post by Ndyil »

Title says it all really, a temp fix until Egosoft fixes it properly.(though it is not retroactive unfortunately, since if you have progressed beyond this point your ships have been destroyed for good)

I simply commented out the line <destroy_object object="$TakenPlayerShipsCluster"/> in md\Plot_ep1_ch02.xml to avoid a race condition causing your ships to more often than not get destroyed before they managed to warp out of the pocket cluster the game hides them in.

Edit: Updated script for game version 1.20 and also implemented properly removing the cluster.

Link: http://www.nexusmods.com/xrebirth/mods/192/?
Last edited by Ndyil on Sat, 14. Dec 13, 02:18, edited 2 times in total.
Scoob
Posts: 11173
Joined: Thu, 27. Feb 03, 22:28
x4

Post by Scoob »

Nice.

I've actually been looking at this from the other angle, i.e. restoring the ship once it's been lost. Unfortunately, it's a save edit with a copy-paste from an earlier save. While the ship is in limbo, it remains in your save & could be restored, however, as you've discovered, once it fails to be given back, it's destroyed.

Scoob.
Ndyil
Posts: 44
Joined: Sat, 23. Nov 13, 04:57

Post by Ndyil »

Thanks! And just to note,.. looks like v1.17 has no changes to the file this mod modifies, so it should still work in 1.17.
TinkerToy
Posts: 195
Joined: Fri, 25. Dec 09, 17:41
x4

Post by TinkerToy »

I love you OP !


After 51 hours of trying and 8 campaign restarts, I can FINALLY move on to De Vries with a clear conscience. No save game file edited !

This fix worked perfectly !


I winder if it's worth trying to add that line into the start of the next chapter ? I'd hate my game to crash in a week's time because that "secret cluster" was never deleted... :D
Ndyil
Posts: 44
Joined: Sat, 23. Nov 13, 04:57

Post by Ndyil »

Should be fine. If it were a script that fired more than once or regularly I'd be concerned about the leak accumulating enough to cause issues, but as is it only ever fires once, so it will only leave a single empty cluster leaked.

If I were to fix it more thoroughly, instead of commenting out the <destroy_object object="$TakenPlayerShipsCluster"/> line I'd convert the taken ships list to a group, add a new cue to the quest that triggers when all the elements in the group have changed cluster, then move the <destroy_object object="$TakenPlayerShipsCluster"/> line to the actions taken when the new cue triggers. But I don't feel like testing that.
User avatar
Bloody_Kain
Posts: 881
Joined: Sun, 12. Aug 07, 18:15
x4

Post by Bloody_Kain »

Another Time a Modder saves the Day before an official Patch with this Function is out.

Hmm, how long will it be before this is in a offizial Patch?
Tomottow? Monday? Next Week? ^^
A scattered dream that’s like a far-off memory…
A far-off memory that’s like a scattered Dream…
I want to line the pieces up -
Yours and mine…

P.S.: Ich gehöre zu den 1% der "Hardcorefans" mit Problemen in X Rebirth!
Eng:
I belong to the 1% of "hardcore fans" with problems in X Rebirth!
wullf
Posts: 97
Joined: Mon, 27. Jul 09, 17:28
x4

Post by wullf »

wow tnx alot mate
u just saved my day
sabrehawk
Posts: 113
Joined: Thu, 27. Dec 07, 19:49
xr

Post by sabrehawk »

seriously how did ANYONE ever get past that problem without editing save games? I have tried too over 50 hours and a dozen restarts and it NEVER worked. Now im in 1.18 hotfix 1 and still 1 or 2 hours away from getting to that spot...
Ndyil
Posts: 44
Joined: Sat, 23. Nov 13, 04:57

Post by Ndyil »

I presume you mean other than this fix? Without this fix it is simply a race condition. There is nothing you can do to guarantee it will work or increase the odds of it working, you would just have to get extremely lucky.
nalim27
Posts: 363
Joined: Tue, 24. Jan 06, 20:04
x4

Post by nalim27 »

Bloody_Kain wrote:Another Time a Modder saves the Day before an official Patch with this Function is out.

Hmm, how long will it be before this is in a offizial Patch?
Tomottow? Monday? Next Week? ^^
Hmmm my opinion is 3 months
Mine rig - X4 ready :-) Windows 10 64b
CPU: AMD Ryzen 2700X (stock clocks 3.7GHz + 4.3GHz boost), 32GB DDR4 3200MHz CL14 RAM,
GPU: AMD Vega64 8 GB HBM, played on 2569x1440, Freesync2
SSD: Samsung 970 EVO 1TB M.2 PCI-ex

CPU before 1.7.2018: Intel Xeon E5450@3.6GHz, 8GB DDR2 800MHz RAM,
sabrehawk
Posts: 113
Joined: Thu, 27. Dec 07, 19:49
xr

Post by sabrehawk »

This mod IS modifying your savegame. And it does not revert the change when deactivated. Also it instantly crashes my savegame in 1.18B
Ndyil
Posts: 44
Joined: Sat, 23. Nov 13, 04:57

Post by Ndyil »

I haven't tested it for the beta 1.18, I'd have to see if they made changes that conflict with this mod. However, it would be far more useful for you to give more information rather than jumping to conclusions on what is crashing your game.
Ndyil
Posts: 44
Joined: Sat, 23. Nov 13, 04:57

Post by Ndyil »

Just dl'd the 1.18beta, checked the files, and tested if the mod still works. There have been no changes to the mission script this mod edits and the mod still works for me.(loaded my old 1.17 save just before the ships are returned and they got returned with no crash) Dunno whats crashing your game, would need more information to help you.
Scoob
Posts: 11173
Joined: Thu, 27. Feb 03, 22:28
x4

Post by Scoob »

Worked perfectly for me in v1.18, hence why I recommended it to Sabrehawk in the other thread.

Scoob.
sabrehawk
Posts: 113
Joined: Thu, 27. Dec 07, 19:49
xr

Post by sabrehawk »

the exact timing seems to be the crucial part...im obivously missing a thing
here..

lets say i revert to a save just before prison break battle. finish the battle. borman says we need to jump out . we jump out , arrive, the message of the compound raiders comes in that they secured the ships. (just before that i tried the mod, that may have been to early?) ok i need to fly towards the jump gate system and exit 1 system earlier to save the game , exit the game, apply the mod, load the save and then take the final highway to destination?

And ontop just the fact that we are sitting here working out such an obivous bug for DAYS and the devs dont bother to fix this bloody thing RIGHT NOW
drives me mad...im probably like sheldon who cant just let things go and if something doesnt work right i go awol about it.
Ndyil
Posts: 44
Joined: Sat, 23. Nov 13, 04:57

Post by Ndyil »

The conversation that occurs right as you are arriving at the gate to DeVries in Albion after capturing the prison ship is where the ships get given back, they're given to you at the same time as you are given the free constructor ship. So as long as you have the mod installed during that conversation you will get any taken ships back at the end of it. Whether or not you have it installed or uninstalled at other times does not matter.
sabrehawk
Posts: 113
Joined: Thu, 27. Dec 07, 19:49
xr

Post by sabrehawk »

oh yeah? why does it kill my savegame causing it to crash back to the main menu and givign the error message about the unknown cluster then?

md\Plot_ep1_ch02.xml where shall i find this file? It doesnt exist in the gamefolder.
Ndyil
Posts: 44
Joined: Sat, 23. Nov 13, 04:57

Post by Ndyil »

What is the exact error message you are getting? When is it/the crash occuring(try and be specific)?
Do you have a save file right before the crash I could see?

Most of the game's data files are packed into the *.dat files, not loose in the game's folder. If you want to look at the base game's version of the file you would have to use one of the CAT extracter tools, which you should have no trouble finding in the modding forum.
Ndyil
Posts: 44
Joined: Sat, 23. Nov 13, 04:57

Post by Ndyil »

Updated script for game version 1.20 and also implemented properly removing the cluster.

Leaving the previous file version up for those who are still on 1.19 though.
jojorne
Posts: 867
Joined: Sun, 17. Nov 13, 17:25
x4

Post by jojorne »

[13.000000]={
["timestamp"]=1387141485.000000,
["message"]="Error: LookupKeyName::LookupName(): The key name \"diff\" is not recognized in lookup 'ScriptXML'. Originated from: \"extensions\\FixShipReturn\\md\\Plot_ep1_ch2.xml.(pck|xml)\"",},
[14.000000]={
["timestamp"]=1387141485.000000,
["message"]="Error: LookupKeyName::LookupName(): The key name \"sel\" is not recognized in lookup 'ScriptXML'. Originated from: \"\"",},
[15.000000]={
["timestamp"]=1387141485.000000,
["message"]="Error: LookupKeyName::LookupName(): The key name \"remove\" is not recognized in lookup 'ScriptXML'. Originated from: \"extensions\\FixShipReturn\\md\\Plot_ep1_ch2.xml.(pck|xml)\"",},
[16.000000]={
["timestamp"]=1387141485.000000,
["message"]="Error: LookupKeyName::LookupName(): The key name \"add\" is not recognized in lookup 'ScriptXML'. Originated from: \"extensions\\FixShipReturn\\md\\Plot_ep1_ch2.xml.(pck|xml)\"",},
[17.000000]={
["timestamp"]=1387141485.000000,
["message"]="Error: Error loading MD file extensions\\FixShipReturn\\md\\Plot_ep1_ch2.xml: Invalid root node",},
i did something wrong?

Return to “X Rebirth - Scripts and Modding”