Jump to content

Remote Staging


Recommended Posts

I'm curious if there's an elegant way to trigger a stage event on the non-active vessel. Simply using "Staging.ActivateNextStage()" isn't an option unfortunately, since it always stages the active vessel, and there seemingly isn't any way to feed it a vessel variable. I had high hopes for "vessel.ActionGroups.ToggleGroup(KSPActionGroup.Stage), but it apparently does nothing useful.

I've looked into a few other, less elegant options, such as iterating through each part in a stage and manually activating it, and while this does work it doesn't clear out the stage, since KSP thinks that stage is still valid. Deleting the stage after that and redrawing the staging icons also seemingly didn't work. So far, every alternate method I've found of staging a remote vessel comes with it's own set of serious downsides.

Anyone have any ideas?

Link to comment
Share on other sites

Still no progress and I've tried just about everything I can think of.

However, an idea just occurred to me. I'm at work at the moment, and so can't really investigate, but can't KOS stage non-active vessels? I seem to recall watching a video of a dual launch that involved simultaneous staging of the active vessel and it's KOS controlled counterpart, which was flying around 500 meters away.

Anyone know if it's remote staging system also leaves empty stages, or if not, how it works?

Once I get home I'll investigate this some more.

Link to comment
Share on other sites

I also couldn't find any helpful code in KSP, since it looks like it was created with only the active vessel in mind. You might be able to simulate it, by calling part.activate(stage, vessel) manually. You might have to do other stuff as well, like adjusting the vessels active stage or firing events (though other mods won't like that anyway). Also keep in mind that unloaded vessels might be a problem, since this does not work with those (for obvious reason).

Link to comment
Share on other sites

I also couldn't find any helpful code in KSP, since it looks like it was created with only the active vessel in mind. You might be able to simulate it, by calling part.activate(stage, vessel) manually. You might have to do other stuff as well, like adjusting the vessels active stage or firing events (though other mods won't like that anyway). Also keep in mind that unloaded vessels might be a problem, since this does not work with those (for obvious reason).

Alright. Well, I guess we can close the case on this one.

I can't find a good way to do this, so I'm just going to stick with manually activating each part in a stage, moving that part to the vessel's current stage, which removes the visible empty stage, and then using Stage.ActivateNextStage() on the active vessel to remove the invisible empty stage. Not pretty, but it does seem to work. Thanks for the input Faark.

Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

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