Jump to content

[1.12.x] Ship Manifest (Crew, Science, & Resources) - v 6.0.8.0 - 28 Apr 23


Papa_Joe

Recommended Posts

7 minutes ago, LudificorPayne said:

Here's the popup from Zero MiniAVC . I'm going to proceed through the loading if able and check the log.

  Hide contents

<ylk6Z6f.png

 

Ok.  it is simply checking for duplicates.  The problem with that is that these files are not actually code.  they are interfaces, allowing communication from one mod to another. so they will not cause issues in actual fact.  SO I"m thinking that a whitelist may be needed.  Otherwise I can look into using the CLSInterfaces from CLS instead of embedding a copy in my mod.  However, since there are no errors in operation, I'm not inclined to fix what "isn't broken".  I think that Zero Mini AVC is reporting a false flag.  It is doing what it is designed to do, but reporting a problem that doesn't exist.

 

Link to comment
Share on other sites

2 hours ago, Papa_Joe said:

Ok.  it is simply checking for duplicates.  The problem with that is that these files are not actually code.  they are interfaces, allowing communication from one mod to another. so they will not cause issues in actual fact.  SO I"m thinking that a whitelist may be needed.  Otherwise I can look into using the CLSInterfaces from CLS instead of embedding a copy in my mod.  However, since there are no errors in operation, I'm not inclined to fix what "isn't broken".  I think that Zero Mini AVC is reporting a false flag.  It is doing what it is designed to do, but reporting a problem that doesn't exist.

It is broken, and it is a problem.

There is a KSP 1.12 bug in the plugin loader, triggered when two (or more) *.dll with the same name exist in the GameData folder/subfolders (https://bugs.kerbalspaceprogram.com/issues/28036)
It cause the plugin loader to either :
- outright crash with an ArgumentOutOfRangeException and KSP getting stuck on the "loading part upgrades" loading step
- silently remove random assemblies to be loaded
- continue without side effects.

Which outcome you get depends on the alphabetical loading order of the dlls, and consequently can't be predicted.
It also can't be fixed with a plugin, as this happen before any plugin has any chance to execute.
LGG implemented that warning in ZeroMiniAVC to detect the second and third cases, but it can't cover the first one.

From a mod author POV, there is a workaround : if your redistribute a *.dll that has any chance to also be redistributed by another mod (API, external library...), rename it to something reasonably unique.
So in your case, you can rename the "CLSInterfaces.dll" redistributed by Ship Manifest to something like "CLSInterfaces_ShipManifest.dll"
Internally, it doesn't matter if those dll have different names. Only one assembly (by assembly internal name as defined in the AssemblyInfo.cs file) will actually be loaded, and all other assemblies will correctly get that common reference.

This was actually discussed extensively in the CLS thread recently : https://forum.kerbalspaceprogram.com/index.php?/topic/192130-111-connected-living-spaces-adopted-2006-2020-12-29/&do=findComment&comment=4048902

 

Edited by Gotmachine
Link to comment
Share on other sites

7 hours ago, Gotmachine said:

It is broken, and it is a problem.

There is a KSP 1.12 bug in the plugin loader, triggered when two (or more) *.dll with the same name exist in the GameData folder/subfolders (https://bugs.kerbalspaceprogram.com/issues/28036)
It cause the plugin loader to either :
- outright crash with an ArgumentOutOfRangeException and KSP getting stuck on the "loading part upgrades" loading step
- silently remove random assemblies to be loaded
- continue without side effects.

Which outcome you get depends on the alphabetical loading order of the dlls, and consequently can't be predicted.
It also can't be fixed with a plugin, as this happen before any plugin has any chance to execute.
LGG implemented that warning in ZeroMiniAVC to detect the second and third cases, but it can't cover the first one.

From a mod author POV, there is a workaround : if your redistribute a *.dll that has any chance to also be redistributed by another mod (API, external library...), rename it to something reasonably unique.
So in your case, you can rename the "CLSInterfaces.dll" redistributed by Ship Manifest to something like "CLSInterfaces_ShipManifest.dll"
Internally, it doesn't matter if those dll have different names. Only one assembly (by assembly internal name as defined in the AssemblyInfo.cs file) will actually be loaded, and all other assemblies will correctly get that common reference.

This was actually discussed extensively in the CLS thread recently : https://forum.kerbalspaceprogram.com/index.php?/topic/192130-111-connected-living-spaces-adopted-2006-2020-12-29/&do=findComment&comment=4048902

 

Indeed.  Thanks for the info on the bug.  I admit I've been away for a while and am not up to date.  After Posting, I realized I could simply rename the dll as part of my distribution.  I will do that on the next release.  In the short term you can safely remove the CLSInterfaces.dll from the SM install if you have CLS loaded and you encounter issues.

Edited by Papa_Joe
Link to comment
Share on other sites

After I used the SM fuel transfer - which finished as the trarget tank is full - I cannot close the UI windows as they claim "Action in progress. Cannot close window".
This is annoying, not being able to close the windows.
A look in the log - no exceptions. Well.
I hope a scene change will fix this.

Edit: yep it did but I removed it for now, especially as a new build is in reach.

Edited by Gordon Dry
Link to comment
Share on other sites

I'm using 6.0.3.0 to transfer individual science experiments between containers. My goal is to separate experiments that can be returned to Kerbin for points. These get hopelessly tangled when using the "collect all" function.  I see SM can transfer a single experiment - yay! But it would be nice if the mouse-over info showed all the data in the stock panel, like this:

p8MsQWP.jpg

As it is, I need to scroll through both menus: stock to see the recovery value and SM to transfer it. 

Also the "xmit value" is a bit misleading - I'd call it xmit ratio. 

What does transfer processed / not processed mean? It has been processed in an attached lab I suppose? But I have multiple labs so does it mean processed in one lab or all labs? Thanks

Link to comment
Share on other sites

On 11/25/2021 at 2:46 PM, Gordon Dry said:

After I used the SM fuel transfer - which finished as the trarget tank is full - I cannot close the UI windows as they claim "Action in progress. Cannot close window".
This is annoying, not being able to close the windows.
A look in the log - no exceptions. Well.
I hope a scene change will fix this.

Edit: yep it did but I removed it for now, especially as a new build is in reach.

That sounds like a rounding error issue with the float values.  I'll look at the termination logic for fuel transfers.  I've seen this in the past, but thought I had it licked.  If you can capture a screen shot when it happens, that might help.  Did the details pane show that the transfer was complete, meaning that the xfer buttons and labels returned to normal, and only the close button failed?  Were pump sounds still running or not?

 

On 11/26/2021 at 12:09 PM, Krazy1 said:

I'm using 6.0.3.0 to transfer individual science experiments between containers. My goal is to separate experiments that can be returned to Kerbin for points. These get hopelessly tangled when using the "collect all" function.  I see SM can transfer a single experiment - yay! But it would be nice if the mouse-over info showed all the data in the stock panel, like this:

p8MsQWP.jpg

As it is, I need to scroll through both menus: stock to see the recovery value and SM to transfer it. 

Also the "xmit value" is a bit misleading - I'd call it xmit ratio. 

What does transfer processed / not processed mean? It has been processed in an attached lab I suppose? But I have multiple labs so does it mean processed in one lab or all labs? Thanks

Thanks for the feedback on the science section.  I can't make any changes for the upcoming release, but I will look into this.  Part may be a fix to labels for clarification, and the other is a feature enhancement.

 

In other news, I've completed the CLS update and am preparing a release.  I have an SM release following that. 

Edited by Papa_Joe
Link to comment
Share on other sites

New version!  Available on Git, SpaceDock and Curse.  As for CKAN, file should update normally.  @HebaruSan I have renamed the CLSInterfaces.dll file to SM_CLSInterface.dll.  it is a required file for SM. Just a heads up as you will no longer need to rename in this or future releases for SM.

Version 6.0.3.1 - Release 27 Nov 2021 - KSP 1.12.2
-------------------------------------------------
 - New: Added support for changing vessel types in Vessel Control panel
 - Changed:  Refactored Vessel Control Panel localization strings to improve performance.  This is the start of an application wide refactor to make all localization string usage static instead of instanced
 - Fixed: Corrected potential dll conflict error with CLS. Changed name of CLSInterfaces.dll to SM_CLSInterface.dll. Do not remove this file, it is required.
 - Updated SM_CLSInterface.dll to version 2.0.1.0 (latest CLS released version for KSP 1.12.x).
 

I've not resolved the fuel transfer issue, as I've not been able to duplicate.  I'm sure that is because I've not properly set up the test, but I don't want to be drawing straws to figure it out.  @Gordon Dry, if you encounter the error, provide me a screen shot of the transfer window.  It should help me to characterize the issue.  There are fair number of moving parts in that code (multi resource, multi part, vessel to vessel, etc), so I do need to see the conditions under which the error occurs.

I will also look into the Science data request for the next release.

Enjoy!

Link to comment
Share on other sites

  • 2 weeks later...

I was notified by this thread that the ability to change suits in flight was desirable: 

So, I'll  be adding that to the Roster Window as a column and an edit button for suits.  Next release you will be able to change suits in flight.  Any comments as to the kind of restrictions I should/could place on this feature for Realism, etc.?  Are there any suit mods I should be aware of for integration (given my hiatus)?

 

Edited by Papa_Joe
Link to comment
Share on other sites

On 12/5/2021 at 4:31 PM, Doc Shaftoe said:

Benjee10's historic suit pack has a plugin that allows for separate IVA and EVA textures and normal maps with the stock suit switcher, but I don't think it works for different suit types. At least not yet.

Thanks, I'll look into it and see if integration is possible.

Link to comment
Share on other sites

12 minutes ago, Stone Blue said:

@Papa_Joe Angel's Sunkworks has custom wetsuits.. ??

EDIT: I just realised, he already has a method to switch suits in game :P
 

 

Thanks.  I'll still take a look.  Who knows?  Also, I've implemented the suit type switching.  both in Space Center for crew in flight and for in flight.  It is unaffected by realism as changing suits is something any astronaut should be able to do, but it is limited to only those that have the expansion to support it.  I have other things I'm working on for this next release so it will be a little while before I'll be ready to publish.

Link to comment
Share on other sites

OK, so I've taken some time to look over @micha's thread during his support of Ship manifest. There are several issues / questions I will attempt to address.  Some are older but still relevant. I will be adding these items to the Issues in Github.

  1.  d.frison asked about Kerbalism support.  I've not looked into this, but I will.  adding to my issues list in Github
  2. Dirk asked a question about how SM decides how to identify vessels.  This is indeed a complicated thing. 
    • First, each launch has a Flight ID, which is attached to each part of a launched vessel.  It would be nice if you could use this, but if you build a station, then it will likely contain multiple flight IDs.  So another means must be used. 
    • The docking nodes contain vessel information relating to the vessel names of their parent parts.  this is a good starting point, but you need to traverse up the path to a command pod of some kind to consider it a separate vessel. 
    • Typically, each vessel contains only one command pod, (certainly not a requirement, but there will be only one parent part and the Command pod will be that part (the first part you place in the VAB when you start your ship design).  While this works pretty well, it is not perfect.
    • Therefore, Using the docking node as the start, I treat all parts connected behind a docking module that contain a command pod as a separate vessel.  If someone can find a better method, I'm all ears.

      Let me know if you have issues with the vessel identification system.  I'm very interested in improving this feature to be more robust and more efficient.
  3. Tokamak found an issue with lost Kerbals when transferring to a full part.  I recall issues with that in the past.  I will review the code.  Added to the Issue list.
  4. Resizing of windows has been a recurring request.  It is not a simple matter.  there are a lot of dynamic tabs to address.  There is an issue in Github already for this.  I would appreciate any feedback on how you want that resizing to behave.  I put effort into making the window as compact as possible, as back when the mod was created (2013), huge monitors were not the norm.  As I stated, I've done window resizing for BDA, so I can leverage some of the code there to simplify the process.  I will not work on this until I have some feedback on desired behavior.  Does it need to resize both vertically and horizontally? do buttons need to be bigger, etc.
  5. Flart requested Crew transfers without sound and delay.  I talked about this one before, I think.  I'm working on that for the next release.  It will have a realism switch, as that simulates the time it takes to move from one module to another.  Instantaneous Transfers are not realistic... :D

 

If I've missed any, please go to the issues tab in Github and enter an issue for your particular need.  That is where I will be tracking bugs going forward.  Reading thru the forums is great, but things can get lost there.  If you want it to be addressed, open an issue.  Issues · PapaJoesSoup/ShipManifest (github.com)

Here is the preliminary Change log for the upcoming 6.0.4.0 release:
These items have been completed.
--------------------------------------------------
 - New: Added support to the Roster Window for selecting spacesuits while in Space Center and in Flight for assigned Crew.
 - Changed:  Complete Refactoring of localization strings to improve performance and maintainability.
   This completes the application wide refactor to make all localization string usage static
   instead of instanced.
   Components affected:
   - Manifest Window
   - Transfer Window
   - Roster Window
   - Settings Window and all tabs
   - Control Window and remaining tabs
 - Fixed: Replaced hard coded string in Settings.Config Tab to use localization "(lines)".
   Updated localization files to include new reference.
 - Fixed: Restored Input UI screen locks.  Some UI elements cannot be blocked, such as the Crew Portraits, and the Control panel at the top of the screen.
   Click thru will still occur in these areas.
 - Fixed: incorrect localization string references in Science Tab.  Lab Boost should now read Xmit Bonus.  Some ToolTips were incorrect.
-----------------------------------------------------------

Thanks!

Edited by Papa_Joe
Link to comment
Share on other sites

33 minutes ago, Papa_Joe said:

Kerbalism support

I guess the most important thing is the way Kerbalism handles science. There is a "Transfer Data here" button on any controllable part with a "HardDrive" when more than one part with a HardDrive is in the vessel - and a "HardDrive" can store data and/or samples in slots.
There is a difficulty setting as well, to toggle the possibility to move samples automatically (by pressing that "Transfer Data here" button) or only when a scientist is on board.

I suggest that Kerbalism's setting gets priority for the handling of samples. So the SM method of moving science should trigger the Kerbalism method (I don't know if there is an API for that @Gotmachine) and obey the Kerbalism difficulty setting,

Edited by Gordon Dry
Link to comment
Share on other sites

45 minutes ago, Papa_Joe said:

Does it need to resize both vertically and horizontally? do buttons need to be bigger, etc.

vertical resize have more priority, than horizontal, size of the buttons are ok.

the most priority is for the vertical resize of the upper side of the crew transfer and fuel transfer windows
(upper side — where the parts selector)

 

Another feature: right click on the app icon opens specified in the settings window at ones (crew transfer, fuel transfer, etc.), without the main window

Edited by flart
Link to comment
Share on other sites

7 hours ago, flart said:

...

Another feature: right click on the app icon opens specified in the settings window at ones (crew transfer, fuel transfer, etc.), without the main window

Not sure what you are asking for here.  Can you elaborate?

Link to comment
Share on other sites

In the [x] science mod, the right click and the left click on the icon in the toolbar could open different mod windows. 

Same could be done there:
the left click opens the main SM window (as it is now), but the right click on the icon open the most used by user Transfer window, for example, the Fuel Transfer window.

So if I am using Fuel Transfer window often, I could just right click on the SM icon in the toolbar.
 

Link to comment
Share on other sites

21 hours ago, flart said:

In the [x] science mod, the right click and the left click on the icon in the toolbar could open different mod windows. 

Same could be done there:
the left click opens the main SM window (as it is now), but the right click on the icon open the most used by user Transfer window, for example, the Fuel Transfer window.

So if I am using Fuel Transfer window often, I could just right click on the SM icon in the toolbar.
 

Ok.  I understand what you are envisioning now.  Thanks!

Update:  I've looked into this request, and it is possible to enable right clicking on the ApplicationLauncher object (handler for mod icons).  It will require some refactoring, as there is logic in place that "assumes" the presence of the Default Manifest window.  Not onerous, but it will take a bit of effort.  I'll place this on the Issues list and work it in a future release.  I will also add tooltips to the app icon to clarify possible actions.

Edited by Papa_Joe
right click transfer window is possible
Link to comment
Share on other sites

New release:

Version 6.0.4.0 - Release 12 Dec 2021 - KSP 1.12.2
--------------------------------------------------
- New: Added support to the Roster Window for selecting spacesuits while in Space Center and in Flight for assigned Crew.
 - New: Added  a realism setting for Realistic Crew transfers. you can now disable sounds and delay from Crew Transfers. 
   Previously, you had to disable Realistic Transfers to get similar behavior. Realistic Transfers has been renamed to Realistic Resource Transfers.
   The Realistic Crew transfers option is found under "Enable SM Crew Transfers" in the Realism Tab of the Settings Window.
 - New: Added headers to the Vessels tab to improve readability as well as cleaning up the vessel types editing option buttons look and feel.
 - Changed:  Complete Refactoring of localization strings to improve performance and maintainability.
   This completes the application wide refactor to make all localization string usage static
   instead of instanced.
   Components affected:
   - Manifest Window
   - Transfer Window
   - Roster Window
   - Settings Window and all tabs
   - Control Window and remaining tabs
 - Fixed: Replaced hard coded string in Settings.Config Tab to use localization "(lines)".
   Updated localization files to include new reference.
 - Fixed: Restored Input UI screen locks.  Some UI elements cannot be blocked, such as the Crew Portraits, and the Control panel at the top of the screen.
   Click thru will still occur in these areas.
 - Fixed: incorrect localization string references in Science Tab.  Lab Boost should now read Xmit Bonus.  Some ToolTips were incorrect.

As always, it is available on Git, Spacedock and Curse.  CKAN will update as per their normal sweep schedule.

 

Enjoy!

 

Edited by Papa_Joe
Link to comment
Share on other sites

On 12/12/2021 at 3:41 AM, Papa_Joe said:

It will require some refactoring, as there is logic in place that "assumes" the presence of the Default Manifest window.

yes, possibility to close Default Manifest window if some transfer window is opened it is another good update.

Link to comment
Share on other sites

2 hours ago, Gordon Dry said:

You forgot to update the version file.

Thanks!  I"ll fix that.  Sometimes I forget what parts are automated and what parts aren't. :P

 

Update.  Hmm.  I did do it manually.  It is actually automated.  Looking into what my disconnect is.  Thanks for spotting it.

Found my error.  The build process I use was flawed.  I have to perform a final build after merging my Dev code into the Master Branch.  I performed the final Build before that step.  That prevents the Release package from picking up the new version from the DLL assembly.  Noted and fixed.   @micha did a great job of automating the release process using msbuild.  I've had to "relearn" my original build and release process. :P

 

New release (no version bump) published to all the usual suspects.  This will NOT impact the game in any way, but subsequent downloads will include the fix.  There is NO need to download again, unless you really want to.

Edited by Papa_Joe
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...