Jump to content

[1.12.x] Crew R&R - Crew Rest & Rotation


linuxgurugamer
 Share

Recommended Posts

Aha! I'm chasing down this same issue, and I was approaching it from the direction of it possibly Kerbalism-related. 

Likewise, Kerbalism does not do this by itself, or with a number of other mods installed, but as soon as I got to reintroducing CrewR&R the right-click slowdown / PAW freeze consistently happens.

The 'fix' to the PAW freeze and game slowdown is to grab a new part, drop it in the scene, then pick it up and trash it back into the parts tray. Then the game speeds back up and the PAWs work as expected.

There are never any console messages or NREs displaying while this happens, but I'll also try Notes2Log to see if some unintended interaction can be identified.

It's on KSP 1.11.2 , but I've been noticing this since 1.11 itself I think...

ksp.log
player.log

[edit] I had to figure out how to *actually* use Notes2Log-- I didn't leave notes the first time! :D
Now to pull everything *but* these two mods to see if there are more interactions.

[edit[edit]] I've now gotten this to replicate with *only* Crew R&R, Kerbalism, their dependencies, and Notes2Log present.  Logs updated with annotations.

Spoiler

Screenshot-3.png

 

Edited by Beetlecat
Link to comment
Share on other sites

@Beetlecat There is indeed an issue when Kerbalism + CrewR&R are installed.

This happen when the root part is both crewable and crewed.
I opened a detailed issue here : https://github.com/linuxgurugamer/CrewRandR/issues/14
I doubt that the issue is caused by Kerbalism directly, my guess is that it is revealed by Kerbalism querying crew information on the part, causing CrewR&R to somehow enter a state where it reset the root part crew every frame.

A workaround is to re-root your vessel to a non-crewable part, or simply to remove the assigned kerbals in the crewed root part.

Link to comment
Share on other sites

Posted (edited)
1 hour ago, Gotmachine said:

@Beetlecat There is indeed an issue when Kerbalism + CrewR&R are installed.

This happen when the root part is both crewable and crewed.
I opened a detailed issue here : https://github.com/linuxgurugamer/CrewRandR/issues/14
I doubt that the issue is caused by Kerbalism directly, my guess is that it is revealed by Kerbalism querying crew information on the part, causing CrewR&R to somehow enter a state where it reset the root part crew every frame.

A workaround is to re-root your vessel to a non-crewable part, or simply to remove the assigned kerbals in the crewed root part.

@Beetlecat this may apply to you as well

Based on reading your issue, I reviewed the code.

The bool **manifestNeedsCleaning** is set true on the following conditions:

  • GameEvents.onEditorStarted.Add(OnEditorStarted);
  • GameEvents.onEditorPodPicked.Add(OnEditorPodPicked);
  • GameEvents.onEditorLoad.Add(OnEditorLoad);

So your report tells me that Kerbalism is forcing KSP to trigger one (or more) of these three events.

There is a reason I don't support Kerbalism in any way.  It does strange things.  I have no idea why it would be triggering one of these events, but it is.

While I'm not willing to do a lot of work on this, I've created a debug dll for you to test with:

https://www.dropbox.com/s/v91pu462j5jnlp6/CrewRandR-DLL.zip?dl=0

All this does is to write debug lines to the log file when one of the methods listed above is called.  It would be best to have Kerbalism check to see why it's constantly calling those methods, but if there is a legitimate reason, let me know.  I can try to put in a hack to avoid the problem, but would need to know the result of running this test dll

Specifically, open the log file and look for one (or more) of the following lines of text:

  • CrewRandR: OnEditorPodPicked
  • CrewRandR: OnEditorStarted, has a manifest
  • CrewRandR: OnEditorLoad, loadType is CraftBrowserDialog.LoadType.Normal

 

 

Edited by linuxgurugamer
Link to comment
Share on other sites

3 hours ago, Gotmachine said:

@Beetlecat There is indeed an issue when Kerbalism + CrewR&R are installed.

This happen when the root part is both crewable and crewed.
I opened a detailed issue here : https://github.com/linuxgurugamer/CrewRandR/issues/14
I doubt that the issue is caused by Kerbalism directly, my guess is that it is revealed by Kerbalism querying crew information on the part, causing CrewR&R to somehow enter a state where it reset the root part crew every frame.

A workaround is to re-root your vessel to a non-crewable part, or simply to remove the assigned kerbals in the crewed root part.

I did notice that removing/restoring crew also "cleared" the condition in the editor,  so I'm assuming that my adding/removing parts was particular to command pods (since that was the first panel open in the part tray) as they would trigger crew info refreshing.

Even figuring out what the conflict/issues are is sometimes rewarding , even if it's not an easy / practical fix. ;) 

Appreciate you looking into this, @Gotmachine and to @linuxgurugamer for your feedback & clarification here.

Link to comment
Share on other sites

3 hours ago, linuxgurugamer said:

@Gotmachine has demonstrated to me that this can be triggered even without Kerbalism installed.  It's an oddity inside KSP, since he was kind enough to supply me with a small test code, I'll be able to look at and fix it soon

Cool -- Thanks again to both of you for looking at this.

Link to comment
Share on other sites

I've been able to totally remove CrewR&R from the equation, it's a KSP bug.

Bug report filed here:  https://bugs.kerbalspaceprogram.com/issues/27432

Offending code:

using KSP.UI;

public class TestCrewModule : PartModule 
{
	bool called = false;

	void Update() 
	{
		if (HighLogic.LoadedSceneIsEditor) 
		{
			if (!called) 
			{
				VesselCrewManifest originalVesselManifest = CrewAssignmentDialog.Instance.GetManifest();
				CrewAssignmentDialog.Instance.RefreshCrewLists(originalVesselManifest, true, true);
				called = true;
			}
			var manifest = KSP.UI.CrewAssignmentDialog.Instance.GetManifest();
		}
	}
}

 

Link to comment
Share on other sites

new release, 1.1.11.1

  • Added short-mission mode, where any mission < specified hours will have a much short vacation
  • Thanks to @gotmachine for this:
    • Changed calls to CrewAssignmentDialog.Instance.RefreshCrewLists to change third parameter to false to avoid a KSP bug where the PAW wouldconstant re-instantiation of the PAW by UIPartActionController .Update(), generating huge lag that result in PAWs becoming very unresponsive.
Link to comment
Share on other sites

19 minutes ago, linuxgurugamer said:

Added short-mission mode, where any mission < specified hours will have a much short vacation

No rest for the wicked!  Now no more long breaks after just driving the rover from one end of the KSC to the other. :D

Cheers for the editor fix!! that's fantastic.

Link to comment
Share on other sites

  • 1 month later...

Hi! I'm seeing kerbals disappear from the crew tab and the astronaut complex, while in the context of the VAB. I'm not sure if this is a bug or the intended implementation.

After a flight, the "resting" kerbals will show up in the crew tab, but once I take an action to add/remove crew from a capsule for a subsequent flight, the "resting" kerbals will dissappear . Also, if I click the "astronaut complex" button from the VAB, the resting kerbals don't show there (but I can see them and their timers if I access the astronaut complex from the space center view).

I'm playing on 1.11.2 with no mods other than CrewRandR and its dependencies. I also checked an older game I had (heavily modded 1.9 installation) and the vanishing kerbal behaviour isn't happening there (the resting kerbals simply never show in the crew tab or astronaut complex, when accessed from VAB).

My GameData folder looks like this:
000_ClickThroughBlocker
001_ToolbarControl
CrewRandR
Squad
SquadExpansion

Repro Steps:
1. Create new sandbox file
2. Open VAB, place Mk1 Command Pod
3. Launch (with Jeb) then recover vessel
4. Open VAB, go to crew tab (noticed Jeb shows under "Available Crew")
5. Click "Remove Kerbal from Vessel Button" to remove currently assigned kerbal
6. Observe as Jeb vanishes (and assigned kerbal isn't removed; you need to press the button a second time)

Also, if you trigger this behavior, then switch to a different tab (Action, Build, etc) then switch back to Crew, the resting kerbals will again, and the vanish behaviour will repro once more, if you try to remove the kerbal from the ship.

Here's my save file, if that's useful:
https://drive.google.com/file/d/1_Gmh0e3satRwnoVGtbgQAmmzPDkwpFoa/view?usp=sharing

Link to comment
Share on other sites

  • 1 month later...
On 4/16/2017 at 9:24 PM, linuxgurugamer said:

Features

  • Crew go on R&R after completing a mission, between 7 and 28 days in length, depending on the length of their mission. (configurable)

 

Could you modify the OP to explain the settings for this mod are in the Difficulty settings?  Thanks.

Link to comment
Share on other sites

  • 1 month later...
  • 1 month later...

After spending more than an hour wondering why my crew disappears, copying KSP instances, and finding out that it only happens in career mode

I got the idea to visit the Astronaut Complex and only there did I notice that the crew needs 18 more minutes to recover. The problem with this mod is that it doesn't tell you that the crew is recovering. When your crew straight-up poofs and it's gone when you try to assign them to a vessel, that's... a really bad user experience, I guess.

Player.log https://drive.google.com/file/d/1-Gi-KZ6w_1zjhSac9JaBkUa3ajB9DS-v/view?usp=sharing (Best regards, S.A.V.E. Resaved 1.11.0.1)

Also, there's a typo. This mod is called "Crew R&&R" on CKAN.

Edited by Krzeszny
R&&R
Link to comment
Share on other sites

2 hours ago, Krzeszny said:

I got the idea to visit the Astronaut Complex and only there did I notice that the crew needs 18 more minutes to recover. The problem with this mod is that it doesn't tell you that the crew is recovering. When your crew straight-up poofs and it's gone when you try to assign them to a vessel, that's... a really bad user experience, I guess.

Ummm, this isn't a bug, why are you treating it as one?

And, how would you like to be notified?  And, how often would you like to be notified?

You are literally the first person who ever had this complaint, about a mod which does exactly what you just described.  If it's not what you are expecting, then don't use it.\

I suppose I could spend some of my (limited) time writing a window to show this, but then again, that would merely be duplicating what the Astronaut Complex shows.

So I'm curious as to what you are expecting?

 

2 hours ago, Krzeszny said:

Also, there's a typo. This mod is called "Crew R&&R" on CKAN.

Thank you, will get it fixed

Link to comment
Share on other sites

1 hour ago, linuxgurugamer said:

So I'm curious as to what you are expecting?

I was expecting this mod to either not show resting Kerbonauts on the crew list or display any kind of text message that a particular Kerbal is resting when trying to put them in a command pod. I wasn't expecting any windows or any other UI nor was I expecting having to go to the Astronaut Complex each time before launching a mission or a simulation, simply because it was never required in stock KSP.

 

1 hour ago, linuxgurugamer said:

You are literally the first person who ever had this complaint, about a mod which does exactly what you just described. 

One does not simply expect users to report bugs. Remember the white icon that nobody reported before I did?

Anyway,

Crew tab shows 6 Kebals > you try to put someone in a comand pod > everyone in the crew tab literally disappears. Ok, I was somewhat unlucky that all my Kerbonauts are on a break at the same time, for the first time (I didn't use this mod before), but still, it looks like a bug, considering how many mods I have installed.

I'm not expecting you to fix it if it 's intended but is it really intended? Do you see no problem here?

"My crew disappears when I try to put them in a command pod. I don't know how to fix it and can't play KSP. This is fine :)"

Edited by Krzeszny
Link to comment
Share on other sites

 

2 hours ago, Krzeszny said:

Crew tab shows 6 Kebals > you try to put someone in a comand pod > everyone in the crew tab literally disappears. Ok, I was somewhat unlucky that all my Kerbonauts are on a break at the same time, for the first time (I didn't use this mod before), but still, it looks like a bug, considering how many mods I have installed.

This is something new in 1.12, I didn't realize you were referring to them disappearing while in the editor.  I'll look into it, no ETA.

 

2 hours ago, Krzeszny said:

One does not simply expect users to report bugs. Remember the white icon that nobody reported before I did?

Actually, I do.  Things can't be fixed without bug reports, especially with mods.  And yes, sometimes things don't get reported, in which case those things don't get fixed.

 

Link to comment
Share on other sites

1 hour ago, linuxgurugamer said:

I didn't realize you were referring to them disappearing while in the editor.

So you never watch my bug report videos... is it because of the buzzing microphone? :P

Link to comment
Share on other sites

38 minutes ago, Krzeszny said:

So you never watch my bug report videos... is it because of the buzzing microphone? :P

Lack of time, usually.   An accompanying description is always useful.  Video is useful for elaboration, but a video by itself is, more often than not, useless since I have to ask questions anyway.  I'd rather get the questions asked and then look at a video to understand a description

Link to comment
Share on other sites

7 minutes ago, linuxgurugamer said:

Lack of time, usually.   An accompanying description is always useful.  Video is useful for elaboration, but a video by itself is, more often than not, useless since I have to ask questions anyway.  I'd rather get the questions asked and then look at a video to understand a description

Noted

Link to comment
Share on other sites

8 hours ago, linuxgurugamer said:

Ummm, this isn't a bug, why are you treating it as one?

And, how would you like to be notified?  And, how often would you like to be notified?

You are literally the first person who ever had this complaint, about a mod which does exactly what you just described.  If it's not what you are expecting, then don't use it.\

I suppose I could spend some of my (limited) time writing a window to show this, but then again, that would merely be duplicating what the Astronaut Complex shows.

So I'm curious as to what you are expecting?

LGG maybe he is not making himself clear. Yeah there is something a bit weird happening, easily explainable in words. Less than a bug, more like an oddity. It is harmless and I just ignore it, but it is indeed weird.

Let me explain. Imagine jeb is recovering. In his portrait in the astronaut complex it says so clearly, and the time it takes for his recovery to end.  Sofar so good. And since he is recovering, in the editor he doesnt't appear as available for assignment, right? Wrong, he does. If you click on him to drag him into the ship, he then disapears. Thats what is happening.

It is no gamebreaking issue. It is slightly enerving as most people dont go to the astronaut complex first just to see who is available, they just go to the editor and check there who is available. It is strange to see everyone there, click on a guy to put him into the pod, just to see him vanish and think "oh thats right, I just used him a few days ago".

Edited by Daniel Prates
Link to comment
Share on other sites

24 minutes ago, Daniel Prates said:

LGG maybe he is not making himself clear. Yeah there is something a bit weird happening, easily explainable in words. Less than a bug, more like an oddity. It is harmless and I just ignore it, but it is indeed weird.

Let me explain. Imagine jeb is recovering. In his portrait in the astronaut complex it says so clearly, and the time it takes for his recovery to end.  Sofar so good. And since he is recovering, in the editor he doesnt't appear as available for assignment, right? Wrong, he does. If you click on him to drag him into the ship, he then disapears. Thats what is happening.

It is no gamebreaking issue. It is slightly enerving as most people dont go to the astronaut complex first just to see who is available, they just go to the editor and check there who is available. It is strange to see everyone there, click on a guy to put him into the pod, just to see him vanish and think "oh thats right, I just used him a few days ago".

He actually did make himself clear, as you can see above.

So yes, I am aware of it, no idea what's going on, this is new to 1.12.  No eta, but if I figure it out, will be fixed

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.

 Share

×
×
  • Create New...