Jump to content

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


Papa_Joe

Recommended Posts

Folks, I have sort of a question or mod/feature I am looking for, this in regards to the crew transfer feature of Ship Manifest.

Does any mod exist that uses, or planned feature perhaps for ShipManifest, to randomly switch crew positions/seat on a ship over time?

Meaning: for RP purposes, to very roughly simulate a crews movement throughout a ship, if it has more seats than there are kerbals.

So that for example:

-an engineer/pilot starts in the command module and after timewarp/refocusing on the ship the engineer is moved/sits the docked lander module.

-or a scientist Kerbal is moved to the Crewed Lab, then after some time you get back to the ship to find him in the Hitchhiker.

Would something like this be possible with Ship Manifest?

The mod is Kerbal Hot Seat. Also a codepoet mod. It was a proof of concept mod for Connected Living Space.

I'm not sure it is up to date, but you can try it. If not, I can get with codepoet and update it.

@hab136: Let me study your post and I'll provide a solid response.

Link to comment
Share on other sites

I'm getting the following exception in the Ship Manifest debug console:

Error: Error in: ShipManifestAddon.Awake. Error: System.FormatException: Input string was not in the correct format

at System.Int32.Parse (System.String s) [0x00000] in <filename unknown>:0

at ShipManifest.SMSettings.getRectangle (.ConfigNode WindowsNode, System.String RectName, Rect defaultvalue) [0x00000] in <filename unknown>:0

at ShipManifest.SMSettings.LoadSettings () [0x00000] in <filename unknown>:0

at ShipManifest.SMAddon.Awake () [0x00000] in <filename unknown>:0

Any suggestions on how to recover? (I'm guessing this is trigged by something broken in a config file).

Link to comment
Share on other sites

Deleting SMSettings.dat brought back the settings in the KSC view, but when I selected an (uncrewed) vessel in flight I got these exceptions:

Info: SMAddon.OnGUIAppLauncherReady active...

Info: SMAddon.Start.

Error: Error in: ShipManifestAddon.OnDestroy. System.NullReferenceException: Object reference not set to an instance of an object

at ShipManifest.WindowManifest.set_ShowWindow (Boolean value) [0x00000] in <filename unknown>:0

at ShipManifest.SMAddon.OnDestroy () [0x00000] in <filename unknown>:0

Error: Error in: ShipManifestAddon.Awake. Error: System.FormatException: Input string was not in the correct format

at System.Int32.Parse (System.String s) [0x00000] in <filename unknown>:0

at ShipManifest.SMSettings.getRectangle (.ConfigNode WindowsNode, System.String RectName, Rect defaultvalue) [0x00000] in <filename unknown>:0

at ShipManifest.SMSettings.LoadSettings () [0x00000] in <filename unknown>:0

at ShipManifest.SMAddon.Awake () [0x00000] in <filename unknown>:0

Info: SMAddon.Start.

Info: GetCLSVessel - Active.

Info: GetCLSVessel - clsVessel is null.

info: UpdateCLSSpaces - clsVessel is null... done.

Info: CLS Installed? True

Info: SMAddon.OnGUIAppLauncherReady active...

Error: Error in: ShipManifestAddon.Awake. Error: System.FormatException: Input string was not in the correct format

at System.Int32.Parse (System.String s) [0x00000] in <filename unknown>:0

at ShipManifest.SMSettings.getRectangle (.ConfigNode WindowsNode, System.String RectName, Rect defaultvalue) [0x00000] in <filename unknown>:0

at ShipManifest.SMSettings.LoadSettings () [0x00000] in <filename unknown>:0

at ShipManifest.SMAddon.Awake () [0x00000] in <filename unknown>:0

Info: SMAddon.OnVesselLoaded active...

Info: GetCLSVessel - Active.

Info: GetCLSVessel - clsVessel is null.

Info: GetCLSVessel - Active.

Info: GetCLSVessel - clsVessel is null.

Info: SMAddon.OnVesselChange active...

Info: GetCLSVessel - Active.

Info: GetCLSVessel - clsVessel is null.

Info: GetCLSVessel - Active.

Info: GetCLSVessel - clsVessel is null.

...

On a related note the "Save Log" button shows a clearly befuddled pathname:

Info: File Name = .../Library/Application Support/Steam/SteamApps/common/Kerbal Space Program\GameData\ShipManifest\Plugins\PluginData\DebugLog_912015_92111_AM.txt

(this is on MacOS but this will probably bite linux as well):

The log file exists, it's just named "Kerbal Space Program\GameData\ShipManifest\Plugins\PluginData\DebugLog_912015_92111_AM.txt" and it's in .../Library/Application Support/Steam/SteamApps/common ...

Link to comment
Share on other sites

I get the same issue on mac where the addon disables. It is caused by non-default value in the window position fields. Maybe fractional pixels are just a Mac thing, but the window location can end up with floating point positions. However, the config parsing tries to read as an integer. If you don't move the window but leave it in the default upper left corner position, the problem doesn't happen.

Example config segment:


SM_Windows
{
ManifestPosition
{
x = 296.4063
y = 423.332
width = 320
height = 282
}
}

I guess it either needs to be written as integer or parsed as float to squash this bug. Some exception-handling to revert to default config mightn't hurt either.

Edited by bos
Link to comment
Share on other sites

I get the same issue on mac where the button goes missing (doesn't matter if it is stock toolbar or blizzy). It is caused by non-zero value in the window position fields -- I think mac can end up with floating point positions with decimal, but the config reading tries to force parsing as an integer. If you don't move the window but leave it in the default upper left corner position, the problem doesn't happen.

yes, I'm seeing floating point window positions in the save file. When I next get a chance I'll see if truncating them to integer makes the exceptions go away.

Link to comment
Share on other sites

I get the same issue on mac where the addon disables. It is caused by non-default value in the window position fields. Maybe fractional pixels are just a Mac thing, but the window location can end up with floating point positions. However, the config parsing tries to read as an integer. If you don't move the window but leave it in the default upper left corner position, the problem doesn't happen.

Example config segment:


SM_Windows
{
ManifestPosition
{
x = 296.4063
y = 423.332
width = 320
height = 282
}
}

I guess it either needs to be written as integer or parsed as float to squash this bug. Some exception-handling to revert to default config mightn't hurt either.

yes, I'm seeing floating point window positions in the save file. When I next get a chance I'll see if truncating them to integer makes the exceptions go away.

Interesting. I don't use MAC so any insight is appreciated. I did note that this problem recently manifested itself on MACs after I switched from XML based config files to JSON style. I'll investigate what is going on.

Thanks for the feed back!

I've looked at the code, and I do an int.Parse of the screen x and y positions when loading the configuration. Mac may not be liking the type conversion. So, I can change it to float.Parse, since that is the native type for the rectangle object I'm populating. Not sure why I used int... maybe I was thinking the pixel could not be fractional...

alternatively, I can save int values and remove the fractional portion when saving. If cleaning up the data in the config works, that may be the path I take.

Let me know if changing the screen x/y positions to integers works...

Edited by Papa_Joe
Link to comment
Share on other sites

Small bug report: The tooltip for individual science pieces seems to be positioned at where the item in the list would be if the whole list were on screen, instead of where the item actually is on screen... which means on long lists (90 science items), the tooltip gets lower and lower on screen until it finally goes off screen. Look at how low the tooltip for "Mystery Goo Obesrvation from Minmus's Lesser Flats" is. :)

http://i.imgur.com/rrigHljl.png

If it's not possible to base the tooltip on the item's actual position on screen, you could instead base the tooltip position on the mouse position with something like:

new Rect (Input.mousePosition.x + 20, (Screen.height - Input.mousePosition.y) + 20, size.x, size.y);

Alternatively, just clamp the tooltip window to the screen dimensions so it's never off-screen.. which might be a good idea anyways.

Now that that's out of the way, the reason I was digging through all these science items was to see which ones were:

1. Zero recovery value, but still have lab value (keep it on station to be processed)

2. Zero recovery value, no lab value on this station (send to other station)

3. Positive recovery value, and still have lab value (keep it on station to be processed, then recover)

4. Positive recovery value, but no lab value (recover immediately)

http://i.imgur.com/P9qAPHZ.png

The tooltip gives the lab value (which is correctly shown as zero once already processed), but doesn't actually give the recovery value, so it makes it near impossible to sort based on recovery value.

It's not a huge deal - I'll just sort into "process in lab" and "recover now" and wind up recovering a bunch of zero-value science, but it would be nice to have the recovery value in the tooltip.

It would also be nice to have units on the other values so we have some idea of what it means, something like this:

Data Amount: 28 Mits

Recovery value: 0 science

Transmit value: 100%

Lab Value: 5 data

Data Amount: 160 Mits

Recovery value: 32 science

Transmit value: 20%

Lab Value: 0 data

Actually... what I'd really like is a much larger window that shows all this info at once and gave both the transfer ability as well as the standard buttons too:

[TABLE=class: grid]

[TR]

[TD]Science report[/TD]

[TD]Recovery value[/TD]

[TD]Transmit value[/TD]

[TD]Size[/TD]

[TD]Lab value[/TD]

[TD]Buttons[/TD]

[/TR]

[TR]

[TD]EVA Report from Mun's Poles[/TD]

[TD]0 science[/TD]

[TD]100% (0 science)[/TD]

[TD]28 Mits[/TD]

[TD]0 data[/TD]

[TD][Transmit]

[Delete]

[Process in Lab]

[Transfer][/TD]

[/TR]

[TR]

[TD]Surface Sample from Kerbin's Shores[/TD]

[TD]5 science[/TD]

[TD]20% (1 science)[/TD]

[TD]10 Mits[/TD]

[TD]10 data[/TD]

[TD][Transmit]

[Delete]

[Process in Lab]

[Transfer][/TD]

[/TR]

[TR]

[TD]Crew Report from space just above Duna[/TD]

[TD]30 science[/TD]

[TD]100% (30 science)[/TD]

[TD]5 Mits[/TD]

[TD]300 data[/TD]

[TD][Transmit]

[Delete]

[Process in Lab]

[Transfer][/TD]

[/TR]

[/TABLE]

Hope this gives you some ideas :)

I've been looking at the tooltip position issue, and I think I know the cause. I add an offset to the y position (for readability) and that offset must be accumulating.

Now as far as the position being off screen. I know I added code to prevent that in the x direction. I thought I added it to the Y as well... are you using the latest version? I added screen boundary support to tool tips in version 4.4.1.0.

Sifting thru the rest now...

Edited by Papa_Joe
Link to comment
Share on other sites

That appears to have fixed it. Let me know if you want me to try anything else..

nope. that will help me. Thanks! I'll be sure to save as integer. I also added error handling on load to default values "just in case"

Edited by Papa_Joe
Link to comment
Share on other sites

  • 3 weeks later...
That appears to have fixed it. Let me know if you want me to try anything else..

I have the same problem in ubuntu system, the icons of the mod is missing. The game works fine other than that. But the mod seems to be broken despite of reinstalling the mod. I didnt quite get the solution, and I also like to try it. In which file I should edit the screen positions, and what kind of code should I use?

Thanks.

Link to comment
Share on other sites

I have the same problem in ubuntu system, the icons of the mod is missing. The game works fine other than that. But the mod seems to be broken despite of reinstalling the mod. I didnt quite get the solution, and I also like to try it. In which file I should edit the screen positions, and what kind of code should I use?

Thanks.

.../GameData/ShipManifest/Plugins/PluginData/SMSettings.dat

Look for "x =" and "y =" followed by a floating-point number, and remove the decimal point and everything after it.

Link to comment
Share on other sites

.../GameData/ShipManifest/Plugins/PluginData/SMSettings.dat

Look for "x =" and "y =" followed by a floating-point number, and remove the decimal point and everything after it.

What he said :D. Fix is coming in the next release. I just did a push to Github but am still debugging. Soon.

Hey, Papa_Joe, is this mod not supposed to show on IVA, or have I botched my install? IVA-only is where I think this mod would shine the most!

IVA would work if it was truely an interior based system. at the moment, interior spaces are not "connected" in anyway, so movement from space to space would fail.

Now, that does get me to thinking...

IF, we can detect iva mode (via the currentcamera), then we can exit to the flight scene, perform the transfer and then cut back to the iva. I could look into that.

Edited by Papa_Joe
Link to comment
Share on other sites

.../GameData/ShipManifest/Plugins/PluginData/SMSettings.dat

Look for "x =" and "y =" followed by a floating-point number, and remove the decimal point and everything after it.

What he said :D. Fix is coming in the next release. I just did a push to Github but am still debugging. Soon.

IVA would work if it was truely an interior based system. at the moment, interior spaces are not "connected" in anyway, so movement from space to space would fail.

Now, that does get me to thinking...

IF, we can detect iva mode (via the currentcamera), then we can exit to the flight scene, perform the transfer and then cut back to the iva. I could look into that.

Yep, The boxes are back again, its working. Thanks for the help,

Link to comment
Share on other sites

What he said :D. Fix is coming in the next release. I just did a push to Github but am still debugging. Soon.

IVA would work if it was truely an interior based system. at the moment, interior spaces are not "connected" in anyway, so movement from space to space would fail.

Now, that does get me to thinking...

IF, we can detect iva mode (via the currentcamera), then we can exit to the flight scene, perform the transfer and then cut back to the iva. I could look into that.

To detect if in iva mode:


[COLOR=blue]public[/COLOR] [COLOR=blue]static[/COLOR] [COLOR=blue]bool[/COLOR] IsInIVA()
{
[COLOR=blue]return[/COLOR] [COLOR=#2b91af]CameraManager[/COLOR].Instance.currentCameraMode == [COLOR=#2b91af]CameraManager[/COLOR].[COLOR=#2b91af]CameraMode[/COLOR].IVA || [COLOR=#2b91af]CameraManager[/COLOR].Instance.currentCameraMode == [COLOR=#2b91af]CameraManager[/COLOR].[COLOR=#2b91af]CameraMode[/COLOR].Internal;
}

To switch to flight mode:




[COLOR=#2B91AF]CameraManager[/COLOR].Instance.SetCameraFlight();

To switch to previous camera mode:



[COLOR=#2B91AF]CameraManager[/COLOR].Instance.PreviousCameraMode();

Anyway, it's all in the CameraManager class.

Link to comment
Share on other sites

Hi,

IIRC, the previous incarnation "crew manifest", there was a button you could press to "empty" or "fill" a vessel with crew when still on the launchpad.

Given that KSP has the propensity to re-insert crew into vessels that you have emptied in the VAB, or re-fill with the wrong Kerbonauts, is there a chance we could get this capability back?

Unless its in there somewhere already and I cant find it :)

Cheers

Link to comment
Share on other sites

Hi,

IIRC, the previous incarnation "crew manifest", there was a button you could press to "empty" or "fill" a vessel with crew when still on the launchpad.

Given that KSP has the propensity to re-insert crew into vessels that you have emptied in the VAB, or re-fill with the wrong Kerbonauts, is there a chance we could get this capability back?

Unless its in there somewhere already and I cant find it :)

Cheers

It is still there. You may have to turn off realism setting to get to this functionality.

This link from my wiki may help: https://github.com/PapaJoesSoup/ShipManifest/wiki/2.0---Basic-Operation

- - - Updated - - -

To detect if in iva mode:


[COLOR=blue]public[/COLOR] [COLOR=blue]static[/COLOR] [COLOR=blue]bool[/COLOR] IsInIVA()
{
[COLOR=blue]return[/COLOR] [COLOR=#2b91af]CameraManager[/COLOR].Instance.currentCameraMode == [COLOR=#2b91af]CameraManager[/COLOR].[COLOR=#2b91af]CameraMode[/COLOR].IVA || [COLOR=#2b91af]CameraManager[/COLOR].Instance.currentCameraMode == [COLOR=#2b91af]CameraManager[/COLOR].[COLOR=#2b91af]CameraMode[/COLOR].Internal;
}

To switch to flight mode:




[COLOR=#2B91AF]CameraManager[/COLOR].Instance.SetCameraFlight();

To switch to previous camera mode:



[COLOR=#2B91AF]CameraManager[/COLOR].Instance.PreviousCameraMode();

Anyway, it's all in the CameraManager class.

That is most helpful. I will check that out. Now, having the sm window open in this mode... more to look at.

Link to comment
Share on other sites

Joe, did you ever make any progress on the renaming of the Kerbals? I wanted to make a mix of military (wanted things like Sgt Boo Kerman and Capt. Zap Kerman) and civilians on a long journey mission and see who comes back. Not going to force it, just see who survives the kracken events... And I have Deadly Reentry installed too. I lost one because a wing overheated and went POOF! This ship is a nuclear torch ship going on a system wide journey.

Bit of a science experiment like in the movie 2010, you see... because, well... SCIEEEEEEEEEEEEEEEENCE.

Link to comment
Share on other sites

Hard to believe possible but there is something that could improve ships manifest.

The one thing missing from it is the possibilitie to move things in the inventories around. I agree it's only usefull for users of the KIS mod but nonetheless it would be very nice to move things around in the inventories of kerbals and containers.

Link to comment
Share on other sites

  • 2 weeks later...
  • 2 weeks later...
So I have a question and I have used the search but maybe I'm not finding my answer. It seems after a day of using SM, it disappears in the toolbar. How do I keep it from disappearing like that?

Using Blizzy's toolbar or stock buttons??

For assistance you will need to supply a log file.

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...