File information

Last updated

Original upload

Created by

eabel303

Uploaded by

DustyRumps

Virus scan

Safe to use

About this mod

Fixes FIVE of the known bugs that happen with the "Supply Planet with resource" missions obtained from the mission boards.

Requirements
Permissions and credits
Changelogs
Quick instructions:
1. Install mod.
2. If you are on a new character or haven't done any of the supply missions yet, just play the game.
3. If your character has been doing the supply missions, build the Fixer terminal, push the "Do It!" button. Delete the Fixer Terminal.
The only time you would need the terminal again is if the mod got disabled or another mod conflicted with this mod and it stopped working.
4. If an update is released, just install it. No need to re-run the fixer. 


Version 1.0: Mission says you have shipped material as soon as you make the link. 
The script that runs the mission has a bug which really screws up the math.
It didn't clear out the global variable that was used to track the amount currently shipped. So, when you start a new mission that uses the same variable it might say 1235 of 500 required has been shipped.
The script has been changed to clear the variable when mission is over.
A notification that shows "Transport Link Parameter Reset" has been added when the mission completes so that you know the fix is active.

Because there are 13 possible variables that could have old values stored I made a tool to clear them all at once.
The Supply Mission Fixer tool is located at the bottom of the Decorations list on the build menu. A new Icon has been added to the menu in V1.3.


Version 1.1: Fixed another bug
Sometimes, the cargo ship would pull ALL of the resource out of your storage chain.
So, let's say you had 2,000 Aluminum in a long chain of containers and the supply mission was for 500.
The ship would land and pull all 2,000 out of your storage chain.
Then, when the mission was finished it would put the extra 1,500 Aluminum back into your ship's cargo hold, unless it filled up, in which case it would put the rest of it into your personal inventory.
This bug was in the "SQ_OutpostCargoLinkScript" which has been updated and is included in V1.1's EAASupplyMissionFix - Main.ba2 archive.
Details are below.


Version 1.2: Fixed bug where mission is not shown in your outpost's cargo link screen.
Some of the cargo links out in the Settled Systems are broken. I don't know how many yet, but I know that Hopetown is the main one.
The cargo link activators that you see around the landing pads are actually "activators" that trigger a script when the player gets within range.
This causes a dice roll and new supply missions to be added to the mission board, or not. 
If the cargo link isn't set up correctly then it links a mission to a non-existent cargo link. 

MissionSupplyScript now checks to make sure the cargo link is valid before making a supply mission for it.
If it finds a bad one it won't create a mission for it. The downside is that there will only ever be 1 supply mission at that local mission board.

Hopetown has 1 cargo link activator that is linked to an invisible Helium 3 Hub. I added a picture.
I think it was something left over from when they were going to require ships to be fueled?
I tried to fix Hopetown but couldn't get it to work.


Version 1.3: Fixed 2 bugs:
First bug: When a supply mission "Stalls" and stops transporting material it is because the transport ship stops running it's AI package.
I could not find a way to get the ship working again that doesn't require the player to go to the cargo link and remove/re-enable 
the link, which would work for a while but eventually the same thing would happen.
The solution was to force the mission to complete, regardless of how much material was delivered. Since the player did not choose to reject the mission I decided it was only fair to reward the player the full amount of the mission. (This bug is kind of rare anyway and I only had it when delivering material to Jemsion.)
The notification "Transport Ship AI Failed" is shown briefly before mission is completed. 

Second Bug: When the player REJECTS the mission it is supposed to reward the player for only the amount of material shipped.
Instead, it rewards the full amount, even if only 1 unit was shipped. This has been fixed. I found that the script calculated the new reward amount but did not update the global variable that was used to give the credits to the player.

I also added a statistic to the Fixer tool that shows how many supply missions you have completed.


Compatibility:
The only way to fix these bugs was to edit the scripts: missionsupplyscript, and in V1.1, SQ_OutpostCargoLinkScript.
If you use another mod that edits these scripts then it might override this mod depending on load order. (Not likely though)
It has been tested on 2 different characters on 2 different computers and is working great so far.

This is a small master file.
This mod must be kept in the load order to prevent the problem from re-occurring. The edited script is contained in the archive included with this mod.
If you need to remove the mod, be sure to delete the Supply Mission Fixer tool from outpost, etc before disabling the mod.


I moved the details of the changes I made to the scripts to an article: Script Change Details