Jump to content

[1.9.x] All Y'All Continued - One-Button Common Action Grouping


linuxgurugamer

Recommended Posts

  • 4 weeks later...

Is there a chance this could be expanded to engines, or would that involve too much fiddling around because of the larger risk of unintended consequences? I've been running some aircraft from the Stage 2 SPH (named action groups only, and they were all being used for stuff) and had cause to enable/disable my engines occasionally.

Link to comment
Share on other sites

On 9/6/2018 at 8:28 PM, JH4C said:

Is there a chance this could be expanded to engines, or would that involve too much fiddling around because of the larger risk of unintended consequences? I've been running some aircraft from the Stage 2 SPH (named action groups only, and they were all being used for stuff) and had cause to enable/disable my engines occasionally.

Expanded how?  What sort of functionality are you thinking of?

Link to comment
Share on other sites

58 minutes ago, linuxgurugamer said:

I understand,  but what would activate it?

I would assume it would work the same as with other things, an extra button or two in the right-click menu for the affected parts.

Like I said, I recognise there could be unintended consequences if parts aren't recognised properly (shutting down drive and RCS engines, for example) and I don't expect any real effort to be expended on the idea if it's going to involve more than a couple of lines of code. However, I also recognise the possible utility that adding this to RCS engines could offer, especially with some of those ships you've been building in your streams recently; going from gross to fine control by shutting down a slew of engines could be accomplished by shutting them all off then re-enabling just the one or two blocks you want to keep active, which could save a lot of time and aggravation with setting up extra Action Groups (assuming a career is advanced enough to have access to them.)

It was just a random thought really.

Link to comment
Share on other sites

2 hours ago, JH4C said:

I would assume it would work the same as with other things, an extra button or two in the right-click menu for the affected parts.

Like I said, I recognise there could be unintended consequences if parts aren't recognised properly (shutting down drive and RCS engines, for example) and I don't expect any real effort to be expended on the idea if it's going to involve more than a couple of lines of code. However, I also recognise the possible utility that adding this to RCS engines could offer, especially with some of those ships you've been building in your streams recently; going from gross to fine control by shutting down a slew of engines could be accomplished by shutting them all off then re-enabling just the one or two blocks you want to keep active, which could save a lot of time and aggravation with setting up extra Action Groups (assuming a career is advanced enough to have access to them.)

It was just a random thought really.

That's not really what this mod is for.  This mod is for parts which can automatically trigger an action group based on some situation being met.  You are looking for something different

Link to comment
Share on other sites

5 minutes ago, linuxgurugamer said:

That's not really what this mod is for.  This mod is for parts which can automatically trigger an action group based on some situation being met.  You are looking for something different

?  This mod is for *manual* activation of actions on groups of related parts, *without* having to set up an action group.  Regardless of the situation.  Are you sure you aren't confusing this thread with one of your other mods?

Link to comment
Share on other sites

To continue the discussion, what exactly would you want this to do?  My ideas are:

  • Activate all engines
  • Activate all engines in current stage
  • Activate all engines connected to part
  • Deactivate all engines
  • Deactivate all engines in current stage
  • Deactivate all engines connected to part
  • Activate all RCS
  • Deactivate all RCS
  • Activate all RCS connected to part
  • Deactivate all RCS connected to part

 

Link to comment
Share on other sites

Obviously while rescinding control of the mod I rescinded also its development path, but I figure I'd pop in for a second and comment on why I did not add any options for engines: Button spam and confusion are the two biggest ones, and a close third is that you almost never want to do something to all engines, or even all engines of a specific type. What you generally want with engines is all the ones facing one way to be on or off, and even if the code could find that out (I'm sure it can) I'm sure there would be edge cases where it doesn't perform as expected or desired and then it's just a useless button for that ship, with the added problem that it reads like what the player would want.

"Open all solar panels" is straightforward and does what you expect every time. "Activate all engines" does too but is rarely what is wanted. "Activate all in the current stage" is basically what the spacebar does, or Z. "Deactivate in the current stage" is basically what X does. Anything else is - in my mind - confusing and nonobvious, and/or would require forethought and specific planning in the VAB. And if you're doing that why aren't you just using action groups? :D 

Link to comment
Share on other sites

1 hour ago, 5thHorseman said:

Obviously while rescinding control of the mod I rescinded also its development path, but I figure I'd pop in for a second and comment on why I did not add any options for engines: Button spam and confusion are the two biggest ones, and a close third is that you almost never want to do something to all engines, or even all engines of a specific type. What you generally want with engines is all the ones facing one way to be on or off, and even if the code could find that out (I'm sure it can) I'm sure there would be edge cases where it doesn't perform as expected or desired and then it's just a useless button for that ship, with the added problem that it reads like what the player would want.

"Open all solar panels" is straightforward and does what you expect every time. "Activate all engines" does too but is rarely what is wanted. "Activate all in the current stage" is basically what the spacebar does, or Z. "Deactivate in the current stage" is basically what X does. Anything else is - in my mind - confusing and nonobvious, and/or would require forethought and specific planning in the VAB. And if you're doing that why aren't you just using action groups? :D 

@5thHorseman Always appreciate input from the original author.  And I wasn't aware that X deactived all engines in the current stage.

And, regarding the earlier comment about RCS, it is a lot harder to balance a vessel by turning various rcs on and off than it is to simply change the thrust limiter.

So, I'm not sure I'm going to go ahead with this, unless a compelling case could be made.

Link to comment
Share on other sites

Well, X and Z don't really activate/deactivate engines on *a* stage, they're the throttle controls and they work across *all* activated stages; turning the throttle to zero by pressing X doesn't deactivate a stage, it stops it from producing thrust unless/until Z or left-shift (or whatever you've changed the bindings to) increase the throttle again, whether that input is intentional or accidental.

But I did say that I knew there's a lot of potentially unwanted side-effects that could go along with this. As such, it's probably best left as-is.

Edited by JH4C
typo
Link to comment
Share on other sites

5 hours ago, linuxgurugamer said:

@5thHorseman Always appreciate input from the original author.  And I wasn't aware that X deactived all engines in the current stage.

Key word: Basically. Generally all engines in the current stage are the active engines, and X throttles down all active engines which does the same thing as deactivating them.

If you have any other engines running you're doing weird things that probably take more planning than AYA was originally written to handle. In fact, it was specifically written because I kept forgetting to set action groups on science and solar panels, so if you're using it with tons of planning you're probably using the wrong tool for your job. You CAN open a bottle with a hammer, of course, but if a bottle opener's handy...

Link to comment
Share on other sites

Oh.  It would help if I was in front of the game while replying.

X turns down the throttle, but it doesn't  deactivate them, which means that a engine can accidentally  be turned on by raising the throttle. 

This would be useful with space stations, so maybe I'll  just do that.

Link to comment
Share on other sites

I've gotten both of these implemented, but a question:

For engines which are not in the current stage, I currently have it so that if no engines are activated, the action to enable all engines in the current stage is shown.  In order to not have that message shown when engines are activated, I need to check all parts of a vessel.  This can be quite a performance impactor, so I'm considering one of the following:

  1. Make the checks for this action much slower, about 1x/second
  2. Ignore the fact that the message will be shown on engines which are not in the current stage.  I don't imagine it would be that often that someone will right-click an engine in a stage which is not activated.

Comments?

Link to comment
Share on other sites

I agree with @5thHorseman and @DStaal, what is commonly needed is to disable and reenable the active engines on a stage.  And in cases outside of this, 5thHorseman is right, it's better served by having the player make their own action groups.

As an example, what I've often done with spacecraft is after maneuvering I lock things up so I don't screw up by hitting the keyboard.  As in the easy-to-hit keys, LShift, LCtrl, and Space.  What I do is in either order:

---  Right-click on a single engine or use an action group for multiple engines to disable engines in the current stage
---  R to turn off RCS and then Mod-L to lock staging (if RCS is on, Mod-L still doe translate right just like L :()

And in the reverse order prior to next maneuvering.

What I see this doing is what I do in step #1.  To get the set of engines to toggle, when staging occurs, put all activated engines into a set.  These are the ones to toggle.  When staging occurs next, replace that set with the current set of activated engines.

To ensure you don't get mismatch, you may want to have an option to lock staging along with disabling the engine set.

 

Link to comment
Share on other sites

15 hours ago, linuxgurugamer said:

I've gotten both of these implemented, but a question:

For engines which are not in the current stage, I currently have it so that if no engines are activated, the action to enable all engines in the current stage is shown.  In order to not have that message shown when engines are activated, I need to check all parts of a vessel.  This can be quite a performance impactor, so I'm considering one of the following:

  1. Make the checks for this action much slower, about 1x/second
  2. Ignore the fact that the message will be shown on engines which are not in the current stage.  I don't imagine it would be that often that someone will right-click an engine in a stage which is not activated.

Comments?

Honestly, I'd likely *prefer* it to show on engines that are not in the current stage - under the same logic that has it currently on non-retractable solar panels.  It reduces the amount of thought the player needs to put in to finding the toggle.

Link to comment
Share on other sites

34 minutes ago, DStaal said:

Honestly, I'd likely *prefer* it to show on engines that are not in the current stage - under the same logic that has it currently on non-retractable solar panels.  It reduces the amount of thought the player needs to put in to finding the toggle.

Oh, the activate toggle will be on all engines.  The deactivate will only be on active engines. I was referring to the possibility that the activate toggle will be there all the time, even if some engines are activated.

I've solved this by having a coroutine with a 1 second sleep, so the menu will be updated once a second for this.  Minimal impact to the game, but full functionality for what I want

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