That's great, what was the solution? Just change the OrbitalStation entry into something that your csv is correlating an entry to?
Working on this. Hopefully will have an update in a bit. Trying to keep the fix as simple as possible.
*EDIT*
So, duplicate entries like this:
Object OSLObj = market.getIndustry( "orbitalstation" );
if( OSLObj != null && OSLObj instanceof com.fs.starfarer.api.impl.campaign.econ.impl.OrbitalStation ) {
com.fs.starfarer.api.impl.campaign.econ.impl.OrbitalStation shield = (com.fs.starfarer.api.impl.campaign.econ.impl.OrbitalStation)OSLObj;
float disrupted = shield.getDisruptedDays();
float build = shield.getBuildOrUpgradeProgress();
market = econ.getMarket( market.getId() );
market.removeIndustry( "orbitalstation", null, false );
market.addIndustry( "orbitalstation" );
com.fs.starfarer.api.impl.campaign.econ.impl.OrbitalStationGD newOSL = (com.fs.starfarer.api.impl.campaign.econ.impl.OrbitalStationGD)market.getIndustry( "orbitalstation" );
if( build > 0 ) newOSL.setNewBuild( build );
if( disrupted > 0 ) newOSL.setDisrupted( disrupted, true );
}
but check for faction by:
if (ArcheanOrderEnabled**See below for details) {
if (entity.getMarket().getFactionId() = "hegemony") {
Object OSLObj = market.getIndustry( "orbitalstation_heg" );
if( OSLObj != null && OSLObj instanceof com.fs.starfarer.api.impl.campaign.econ.impl.OrbitalStation ) {
com.fs.starfarer.api.impl.campaign.econ.impl.OrbitalStation shield = (com.fs.starfarer.api.impl.campaign.econ.impl.OrbitalStation)OSLObj;
float disrupted = shield.getDisruptedDays();
float build = shield.getBuildOrUpgradeProgress();
market = econ.getMarket( market.getId() );
market.removeIndustry( "orbitalstation_heg", null, false );
market.addIndustry( "orbitalstation_heg" );
com.fs.starfarer.api.impl.campaign.econ.impl.OrbitalStationGD newOSL = (com.fs.starfarer.api.impl.campaign.econ.impl.OrbitalStationGD)market.getIndustry( "orbitalstation_heg" );
if( build > 0 ) newOSL.setNewBuild( build );
if( disrupted > 0 ) newOSL.setDisrupted( disrupted, true );
}
}
}
** This is a boolean that checks for Archean Order being enabled, so I think Histidine is the best source for direction on how to check for that. If I need to implement anything on my end please let me know. I'm not familiar with how to check for that myself.
also you would have to: change each battlestation and starfortress entry to correlate to the above changes. I can give you the ids you would need if you feel like going through that effort, but no worries if not.
- change each industry check for each faction to correlate to- faction id:industry id with these implementations:
hegemony:orbitalstation_heg
hegemony:battlestation_heg
hegemony:starfortress_heg
luddic_path:orbitalstation_luddic
luddic_path:battlestation_luddic
luddic_path:starfortress_luddic
luddic_church:orbitalstation_luddic
luddic_church:battlestation_luddic
luddic_church:starfortress_luddic
pirates:orbitalstation_pirate
pirates:battlestation_pirate
pirates:starfortress_pirate
trader_guilds:orbitalstation_guilds
trader_guilds:battlestation_guilds
trader_guilds:starfortress_guilds
scicorps:orbitalstation_scicorps
scicorps:battlestation_scicorps
scicorps:starfortress_scicorps
archean_order:orbitalstation_archean
archean_order:battlestation_archean
archean_order:starfortress_archean
adamantine_consortium:orbitalstation_adamantine
adamantine_consortium:battlestation_adamantine
adamantine_consortium:starfortress_adamantine
Note: All of this code would be under the ArcheanOrderEnabled if statement block.
Note2: If any of this is unclear because I can kind of suck at explanations sometimes, PM me and I can hopefully provide code that can be added to an experimental jar to see if it solves the issue.