Jump to content

[1.10.1+] Contract Configurator [v1.30.5] [2020-10-05]


nightingale

Recommended Posts

14 minutes ago, amore555 said:

I'm getting the must not have completed a space tourism contract issue, I didn't realise I wasn't supposed to do so.  How can I utilise the tourism plus contracts?  Using 1.2 pre-release and have this mod up to date by Ckan

It's on the tracker, will be looked at when I have time.

Link to comment
Share on other sites

On 9/28/2016 at 6:42 AM, nightingale said:

A quick compatibility update with the latest builds:

Contract Configurator 1.20.1

  • Moved settings into stock settings screen.
  • Compatibility with latest KSP pre-releases.

Hmm.  When I install 1.20.1 and load up the game, the main menu is unresponsive. I click any menu item and nothing happens. The game responds again after uninstalling.  I have no report about save-games as I can't even get to the screen where the savegame is in place. 

 

In the log, I see a whole lot of reflective loading errors, but I can't tell if that's just logging handled errors in loading.  e.g.

Quote

[EXC 08:38:44.653] ReflectionTypeLoadException: The classes in the module cannot be loaded.
    System.Reflection.Assembly.GetTypes ()
    ContractConfigurator.ContractConfigurator+<GetAllTypes>d__27`1[ContractConfigurator.ParameterFactory].MoveNext ()
    Rethrow as Exception: Error loading types from assembly scatterer, Version=1.0.6039.37649, Culture=neutral, PublicKeyToken=null
    UnityEngine.Debug:LogException(Exception)
    ContractConfigurator.LoggingUtil:LogException(Exception)
    ContractConfigurator.<GetAllTypes>d__27`1:MoveNext()
    System.Linq.<CreateWhereIterator>c__Iterator1D`1:MoveNext()
    ContractConfigurator.ContractConfigurator:RegisterParameterFactories()
    ContractConfigurator.ContractConfigurator:PSystemReady()
    EventVoid:Fire()
    <Start>c__Iterator73:MoveNext()
    UnityEngine.SetupCoroutine:InvokeMoveNext(IEnumerator, IntPtr)

 

For now, it renders the game unusable, sadly. 

Link to comment
Share on other sites

2 hours ago, subitan said:

Hmm.  When I install 1.20.1 and load up the game, the main menu is unresponsive. I click any menu item and nothing happens. The game responds again after uninstalling.  I have no report about save-games as I can't even get to the screen where the savegame is in place. 

 

In the log, I see a whole lot of reflective loading errors, but I can't tell if that's just logging handled errors in loading.  e.g.

 

For now, it renders the game unusable, sadly. 

The error reported is against Scatterer - but shouldn't affect anything with Contract Configurator.  I'd need to see a full KSP.log to do anything here.

Link to comment
Share on other sites

10 hours ago, nightingale said:

The error reported is against Scatterer - but shouldn't affect anything with Contract Configurator.  I'd need to see a full KSP.log to do anything here.

So... it shouldn't affect... but it seems to be loading scatterer (and failing) from within the ContractConfigurator call stack. 

 

I'm trying to figure out how to put the whole log in. This forum UI is really weird, and I cant' figure out how to attach a whole file. 

Link to comment
Share on other sites

Just now, subitan said:

So... it shouldn't affect... but it seems to be loading scatterer (and failing) from within the ContractConfigurator call stack. 

You're reading it incorrectly.  It's looking through the loaded assemblies for contracts to load, and it hits a problem with scatterer (99% sure that it's a KSP version incompatibility).  It then ignores it and moves along.

Just now, subitan said:

I'm trying to figure out how to put the whole log in. This forum UI is really weird, and I cant' figure out how to attach a whole file. 

Please don't post the whole log on the forum (it may let you, but seriously, don't).  Instead put it on pastebin, google drive, dropbox or <your favourite file host here>.

Link to comment
Share on other sites

16 hours ago, nightingale said:

You're reading it incorrectly.  It's looking through the loaded assemblies for contracts to load, and it hits a problem with scatterer (99% sure that it's a KSP version incompatibility).  It then ignores it and moves along.

Please don't post the whole log on the forum (it may let you, but seriously, don't).  Instead put it on pastebin, google drive, dropbox or <your favourite file host here>.

Good call.

And thanks for the reading help.  I'm not a C# guy, and unfamiliar with KSP internals.  I see how it's working now.

All that said, it's still failing, even with SVE removed, which is what supplied scatterer.  The full log is here: http://pastebin.com/e6nwSs0T and (after removing two plugins which had errors) http://pastebin.com/sNmT4T5Y.  However, in all cases, testing with CC and without CC, with fails, without seems to handle the errors.   It's very very weird. 

This is the error I'm seeing in the first log, if that helps:

[EXC 16:09:24.165] MissingMethodException: Cannot create an abstract class 'ContractConfigurator.StockContractParametersTemplate'.
	System.Activator.CheckAbstractType (System.Type type)
	System.Activator.CreateInstance (System.Type type, Boolean nonPublic)
	System.Activator.CreateInstance (System.Type type)
	GameParameters..ctor ()
	GameParameters.SetDifficultyPresets ()
	GameParameters.GetDefaultParameters (Modes mode, Preset p)
	MainMenu.Start ()

But the whole thing is bizarre to me.  It's breaking the main menu, not the rest of the game, and removing CC magically fixes it.  Can't figure out why. Argh. 

Link to comment
Share on other sites

48 minutes ago, subitan said:

Good call.

And thanks for the reading help.  I'm not a C# guy, and unfamiliar with KSP internals.  I see how it's working now.

All that said, it's still failing, even with SVE removed, which is what supplied scatterer.  The full log is here: http://pastebin.com/e6nwSs0T and (after removing two plugins which had errors) http://pastebin.com/sNmT4T5Y.  However, in all cases, testing with CC and without CC, with fails, without seems to handle the errors.   It's very very weird. 

This is the error I'm seeing in the first log, if that helps:


[EXC 16:09:24.165] MissingMethodException: Cannot create an abstract class 'ContractConfigurator.StockContractParametersTemplate'.
	System.Activator.CheckAbstractType (System.Type type)
	System.Activator.CreateInstance (System.Type type, Boolean nonPublic)
	System.Activator.CreateInstance (System.Type type)
	GameParameters..ctor ()
	GameParameters.SetDifficultyPresets ()
	GameParameters.GetDefaultParameters (Modes mode, Preset p)
	MainMenu.Start ()

But the whole thing is bizarre to me.  It's breaking the main menu, not the rest of the game, and removing CC magically fixes it.  Can't figure out why. Argh. 

You will want to update to the latest pre release, I strongly suspect that is the issue.

Link to comment
Share on other sites

@nightingale  Random question for you...how is KSP keeping track of vessel launch time for the newly launched vessels parameters of contracts in the 1.2 pre?  I would have assumed that it was using the vessel's lct value  in the save file but that doesn't appear to be the case.  Thanks.  

Link to comment
Share on other sites

1 hour ago, Tarheel1999 said:

@nightingale  Random question for you...how is KSP keeping track of vessel launch time for the newly launched vessels parameters of contracts in the 1.2 pre?  I would have assumed that it was using the vessel's lct value  in the save file but that doesn't appear to be the case.  Thanks.  

Each part of each craft that is launched gets a launch id (which is monotonically increasing).  When the parameter is initialized, it stores the current launch id.  If a vessel has any part with a launch id that is less than the parameter's stored launch id, the vessel is not considered new.

This applies to both the stock contracts and Contract Configurator.

Link to comment
Share on other sites

On 9/30/2016 at 5:11 PM, nightingale said:

You will want to update to the latest pre release, I strongly suspect that is the issue.

Seems to be fixed now, after the update.  Cool.  Thanks, and thanks very much for the awesome mod!

Link to comment
Share on other sites

I have the latest Pre-KSP 1563 [based on the release log] / 1564 according to the water mark in the lower right corner.

Contract Config Ver:1.20.1.0 [according to the ContractConfigurator.version file
Bug: Picking / Choosing contract categories makes all flight disappear from tracker / game

I don't know if this is a known issue and I did notice it from the previous build 1553

Steps:
1.) Launch game
2.) Start Game > Resume Game > Choose save file

[game loads]

3.) Click on tracking station and observe  that there is allot of stuff in space. [probes, relays, landers, etc]
4.) Click leave facility

5.) Press Esc > Settings > Difficulty Options > Contract Configurator
6.) Un-highlight all but Collect Science
7.) Click Accept > Click Apply > Click Accept > Resume
8.) Click Tracking Station and observe that there is nothing out there and all filters are enabled.
9.) Clicking on Leave Facility does not work.

 

 

Link to comment
Share on other sites

4 hours ago, amore555 said:

@nightingale is the recent news going to affect patches for some of these items?  Also apologies if it's obvious, but where is the bug tracker?  Would be better if i could check there rather than repeat known issues here.

No - no affect on how long it'll take to fix the bugs in Contract Configurator.  They're being worked as I have time, but 1.2 is the priority as the window for that is closing quickly (whereas there's no dealine on CC).

The tracker is here:
https://github.com/jrossignol/ContractConfigurator/issues

Link to comment
Share on other sites

Hello,

Does someone know how (or if there is a way) to specify the time separation between satellites placed on the same orbit?
As example, like for the RemoteTech contract pack, I want to specify a contract to place a train of 3 or 4 satellites on a specific orbit (molniya, tundra or geostationnary in my case), and each orbit must be separated by a period of 8h (for 3 sat) or 6h (4 sats).

Playing with argument of periapsis may work for the geostationary/synchronous orbits (or other circular orbits) but :
 - It actually cannot be retrieved by using the CC's Orbit accessors
 - It cannot work for the molniya and tundra orbits as they are elliptical and then the angular speed and then the absolute angle between satellites varies
 - For circular orbit, the AOP could vary due to inaccuracy to place two sats on exactly the same orbit, especially with equatorial and circular orbit (AOP et LAN become inaccurate).
 - So the Epoch values should be taken into account, but it is not accessible via CC and that will lead to (relatively) complex calculations that require math functions (trigonometry, sqrt, modulo) that are not available in CC.

Link to comment
Share on other sites

5 hours ago, hargn said:

Hello,

Does someone know how (or if there is a way) to specify the time separation between satellites placed on the same orbit?
As example, like for the RemoteTech contract pack, I want to specify a contract to place a train of 3 or 4 satellites on a specific orbit (molniya, tundra or geostationnary in my case), and each orbit must be separated by a period of 8h (for 3 sat) or 6h (4 sats).

Playing with argument of periapsis may work for the geostationary/synchronous orbits (or other circular orbits) but :
 - It actually cannot be retrieved by using the CC's Orbit accessors
 - It cannot work for the molniya and tundra orbits as they are elliptical and then the angular speed and then the absolute angle between satellites varies
 - For circular orbit, the AOP could vary due to inaccuracy to place two sats on exactly the same orbit, especially with equatorial and circular orbit (AOP et LAN become inaccurate).
 - So the Epoch values should be taken into account, but it is not accessible via CC and that will lead to (relatively) complex calculations that require math functions (trigonometry, sqrt, modulo) that are not available in CC.

This is a known limitation without an easy solution.  First of all, nothing in the expression language will (or could) help you - as those are all executed at parse time.  What you need is a parameter that specifies that one or more orbital parameters of a vessel are equal to some value relative to another vessel's orbit.  For n satellites in otherwise identical orbits, it's somewhat straightforward, but gets complicated quickly.

For something like molniya orbits where the goal is to have coverage of a specific geographic area, then I'd do the following:

  • Have a waypoint that is above the spot you want coverage for, at the highest part of the Molniya orbit
  • Have a sequence of parameters that looks something like this:
    • Sat 1 near WP
    • Wait for 8h
    • Sat 2 near WP
    • Wait for 8h
    • Sat 3 near WP
  • To be honest, even the above isn't really good without some enhancements to make it so that everything in the sequence is reset when one of the timers fails.  Otherwise the player can complete sats 1 & 2 and then get stuck.

There's a reason I did it based on coverage and connectivity in the RemoteTech contract pack and didn't try to do too much orbital stuff...

Link to comment
Share on other sites

That could make it, I will test that, but its true that waiting near 3x8h to see that the contract is rejected by the last satellite.
And what happens if the user switch its spaceship? Are the timers reset?
And as I intend to create GNSS constellation contracts, that could become very heavy to write and overvall, to be unserstood by the user.

But it requires some testing.
Thanks
 

Link to comment
Share on other sites

I would like to ask, when exactly contract are (re)generated. In particular, if I put a `Random()` in DATA nodes (or perhaps just anywhere), when those values will refresh?

Edited by pwhk
Link to comment
Share on other sites

6 hours ago, pwhk said:

I would like to ask, when exactly contract are (re)generated. In particular, if I put a `Random()` in DATA nodes (or perhaps just anywhere), when those values will refresh?

They are generated while in the Space Center scene.  There's a pass every 30 seconds or so, but other things can trigger a contract generation attempt.  Note though that the expression are executed on contract generation (so once a Random() value is set for a contract, it won't change for that instance of the contract).

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...