Jump to content

[1.0.5](Nov18/15)Auto Actions: Automatically activate action groups(RCS/SAS) on launch


Recommended Posts

As of KSP 1.2, Teilnehmer has taken over this mod, all future updates can be found here.

 

Auto Actions

Found on the CKAN as Auto Action

-Automatically activate any action group, including RCS and SAS, on vessel launch.

-Set throttle to a desired on vessel creation on a per-vessel basis.

-All settings save on a per-vessel basis

-Supports my Action Groups Extended mod and will activate higher numbered action groups if AGX is present. Will still activate groups 1 through 10 if AGX is not installed.

-Ability to override KSP's action groups lockout in early career mode. Instructions here.

-Version 1.6: KSP 1.0.5 Update.

Download here version 1.6 here. Merge the GameData folder in the .zip with your KSP_Install\GameData folder.

ModuleManager is required. Download it from here.

Support for Blizzy's toolbar is included but optional. If Blizzy's toolbar is not installed, the icon for this mod will show on the stock toolbar.

Regardless of where the icon is, clicking it will show/hide this mod in the editor.

When in Actions editing mode in the VAB or SPH:

AutoAction.jpg

Comments always welcomed.

D.

Edited by Diazo
Link to post
Share on other sites
What about a countdown timer with action groups bound to a certain second?

I wanna do a realistic Saturn V type launch with the different launchclamps disengaging at different times all the way up to launch.

Ooh! That's a cool idea. Especially if you can start countdowns with an action group.

Link to post
Share on other sites

Very nice add-on, Diazo, most useful (I have to redo launch sequences hundred of times for testing purposes, and this add-on is really a time-saver).

Would be perfect for my purposes if could be extended to include also the following actions I repeat everytime before launches:

- stick open the contracts app (in career game) and enlarge to fit with the accepted contracts (believe other players may wish to see other apps opened however);

- in map view, show the navball (default key is keypad period);

- in map view, rotate body to bring the launch position at the view center.

Link to post
Share on other sites
Very nice add-on, Diazo, most useful (I have to redo launch sequences hundred of times for testing purposes, and this add-on is really a time-saver).

Would be perfect for my purposes if could be extended to include also the following actions I repeat everytime before launches:

- stick open the contracts app (in career game) and enlarge to fit with the accepted contracts (believe other players may wish to see other apps opened however);

- in map view, show the navball (default key is keypad period);

- in map view, rotate body to bring the launch position at the view center.

For the Navball by Default there is already a extremely nice mod.

Link to post
Share on other sites

Thanks for the feedback all.

Looking at what people are talking about, a lot of it is out of scope for this mod. This mod is intended as an extension of the editor to all you to "set" all the stuff in the editor that can only be set in flight mode by allowing you to trigger stuff on that first Update when you spawn a new vessel.

-Action group to set the throttle: Out of scope for this mod, however that is planned as a future feature on my Actions Everywhere mod.

-Timed activation of action groups (Saturn V launch): Not happening as the groups would not activate in that first update after launching.

I've actually been struggling with implementing timed action groups at all (it was one of the first things requested when I released AGX) and I've never come up with a way to do them without going the full-on automation route like kOS.

-Open contracts app: Out of scope, that is a UI widget, it's not on the vessel.

-Show navball in map: Again, a UI widget.

-Rotate view: Again, not on the vessel so out of scope.

Really, there really is a "UI Tweaking" mod needed, I don't have the time for that one myself though.

D.

Link to post
Share on other sites

AutoAction.jpg

Abort.... >.>

The confidence of the person utilizing that feature must be as broken as the last 10 launch attempts they made.

:P "Allright kid, so we dont want you to ride the rocket to space, too dangerous. Just get in there, turn on the lights and RCS system, light a fire under your [REDACTED], and then get outa there using the emergency eject system"

Joking aside, its a really simple, small mod. but sometimes, its the little things that make the biggest difference.

Thanks for the contribution to the community, I can see this mod making its way into my core.

Edited by Trollsama
Link to post
Share on other sites
Note that my fight with the KSP GUI continues. The number entry boxes must always have a number in them so you can not delete all characters to enter a new group number. Rather, I recommend highlighting the old number with the mouse and typing the new group in.

This sounds so very familiar :D

In this case, you could use a negative number to indicate that the string should be blank space (ie. if (textField.Text == "") then { val = -1 }, and ofcourse the reverse when printing to the screen)

Link to post
Share on other sites
This sounds so very familiar :D

In this case, you could use a negative number to indicate that the string should be blank space (ie. if (textField.Text == "") then { val = -1 }, and ofcourse the reverse when printing to the screen)

That's not the problem I'm running into. Because I'm using the text boxes as numbers, their must always be a number in the text box. Therefore, when you delete the number to enter a new one, the textbox is left at "" (blank with no characters) which is not a number. This causes it to spaz out and hit my error trap which is go back to the last known good value which is whatever the number you tried to delete is.

How about altitude triggering? Like to pop fairings on the way up?

Nope, that is out of scope for this mod. This mod is only for finalizing your ships settings when it spawns on the launchpad, not for activating anything in flight.

Having said that, check out the Smart Parts mod, I believe it has a part that triggers an action group on altitude and my next project is to make Smart Parts aware of my Action Groups Extended mod so you have more action groups to use them with.

D.

Link to post
Share on other sites
That's not the problem I'm running into. Because I'm using the text boxes as numbers, their must always be a number in the text box. Therefore, when you delete the number to enter a new one, the textbox is left at "" (blank with no characters) which is not a number. This causes it to spaz out and hit my error trap which is go back to the last known good value which is whatever the number you tried to delete is.

You need to check for the blank string before trying to use int32.Parse (edit, convert...) and then encode that as an unusable value is what I was trying to say (and a conversion doing the reverse on the way in).


string masterActivateGroupAString;

// If value is negative, string is blank
if (masterActivateGroupA >= 0)
masterActivateGroupAString = masterActivateGroupA.ToString();
else
masterActivateGroupAString = "";

masterActivateGroupAString = GUI.TextField(new Rect(5, 63, 30, 20), masterActivateGroupAString, 4, AAFldStyle);

// If string is blank, set value negative
if (masterActivateGroupAString == "")
masterActivateGroupA = -1;
else
{
// otherwise proceed as normal
try
{
masterActivateGroupA = Convert.ToInt32(masterActivateGroupAString); //convert string to number
}
catch
{
masterActivateGroupAString = masterActivateGroupA.ToString(); //conversion failed, reset change
}
}

This should catch the blank string and store it as -1, returning it to a blank string for subsequent iterations. As an added bonus, anyone trying to enter negative numbers will have it rejected and turned into a blank screen (I don't believe -ve action group numbers are particularly sane...)

Edited by Crzyrndm
Link to post
Share on other sites
http://members.shaw.ca/diazo/AutoAction.jpg

Abort.... >.>

The confidence of the person utilizing that feature must be as broken as the last 10 launch attempts they made.

Actually this is great for progressive testing of your Rocket NASA style. I use it to test my Kerbal Emergency Escape System Automated (KEESA.) If she isn't properly tested Keesa can be a real pain in the hind-quarters.

Diazo. Thanks for all your brilliant small mods. I have been using Vertical Velocity hold since your first release!

Link to post
Share on other sites

Version 1.1

-KSP 0.90 fix.

You must update to Version 1.1 to run this mod on KSP 0.90 due to code changes under the hood.

This version does not include Crzyrndm's text box fix yet as I want to get started on AGX for KSP 0.90 first.

All my tests are now good, let me know if you run into any issues.

D.

Link to post
Share on other sites

Version 1.2

Download here.

-Stock toolbar support added, will be used if Blizzy's toolbar is not installed.

-Now respects the action groups available in career mode and will only show actions you have access too. Note this means the mod will not show at the start of a career game, you must upgrade the VAB/SPH once to show it.

Comments always welcome.

D.

Link to post
Share on other sites

Greetings Diazo / all;

I am looking for a way to be able to turn SAS (T on the keyboard) on in action group. I want to do this to help with LES systems and other abort methods.

Is there currently a way to do this that I am just not seeing, or can this be done at all.

Happy holidays to all.

Link to post
Share on other sites

@Zeroignite: That should be possible, just did not think of it because Precision Controls isn't actually an action group.

@drtedastro: That is out of scope for this mod, however it is a good suggestion for my Actions Everywhere mod. I should be pushing a new version with some other pilot/SAS stuff in the next few days, I'll try to add it to that.

D.

Link to post
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...