Space Engineers

Space Engineers

Not enough ratings
Blargs Ascent Cruise Control v2.0 Beta
   
Award
Favorite
Favorited
Unfavorite
Tags: autopilot
File Size
Posted
Updated
1.834 MB
6 Sep, 2023 @ 5:43pm
30 May @ 9:41pm
3 Change Notes ( view )

Subscribe to download
Blargs Ascent Cruise Control v2.0 Beta

Description
UPDATE: Sep 12/23 Blargmode updated the original script, so this copy may not be necessary any more

!! NOTE !! THIS IS NOT MY WORK. THIS IS WRITTEN BY BLARGMODE. I AM SIMPLY PUBLISHING IT FOR THE CONVENIENCE OF THE COMMUNITY !! NOTE !! See my rationale for this this below at the end. If Blargmode has a problem with this repub I will take it down.

This is v2.0 (Beta) of Blargmode's Ascent Cruise Control. It adjusts the thrust of your bottom or rear thrusters to the lowest possible without losing speed in order to conserve fuel.

It is completely Blargmode's work, but for some reason they chose not to publish it. However they did provide a link to the source on their public github[github.com] in the v1.0 script comments, and said you could paste the source into a PB and it should work.

Quoting from that site: "Not everything is up to my standards yet but it works fine."

I don't know what Blargmode considered substandard, but I tested it a bunch and it seems solid. And AWESOME.

Here's a link to V1.0 of the script.

Differences from v1.0
Improvements that I have discovered so far
  • amazing graphical presentation
  • descent officially supported, with cutoff altitude specified
  • descent deceleration begins well in advance
  • gravity aligner to keep level (!)
  • even more optimized fuel consumption by using electrics (atmos, ions) as much as possible
Other differences from v1.0
  • lights and timers aren't supported
  • the v1 commands are still supported but there are a bunch of new commands too. The new commands are visible in the PB Detailed Info.
Limitations
The one flaw I've observed is that if you configure "Disable Aligner at zero-G" to "no", then it flips you upside down when you reach zero-g. It also behaves weirdly with the Aligner enabled in space, only allowing you to flip 90-degree increments. I haven't attempted to debug it, but the one single line I changed in Blargmode's work was to default this to "yes".

I haven't tested it, but it looks like small LCDs aren't supported (corner, top/bottom ones). I tested text panel, wide LCD, LCD, transparent LCD, the new LCD inset block, the new LCD inset corner block, and the new holo LCD and they all work. I also tested the main display of the control seat.

I haven't made a thorough study of this script yet but I will do my best to support it.
Setup
Quoting from Blargmode's github:
"There are usage instructions at the top of the file as well as in the terminal output.

But the TL;DR is:
  • Sit in a flight seat during setup.
  • Add #ACC to the name of things with screens for visuals.
  • Multiple screens? #ACC@3 for example to put it on the third screen.
  • Display on PB screen using tag #ACC@0
  • Recompile script after adding screens or issue "reset" command.
  • Send the command "cruise" to the programmable block to toggle cruise control on or off. Can be set in the toolbar by selecting Run on the programmable block and entering the command."

Hard-Won Advice
Each of the following statements I learned from a smoking hole in the ground using v1.0 of the script:

Fair Warning: Inadequate reverse thrust (lift/reverse) can result in catastrophic failure. Ensure your craft has enough propulsion for its mass, docked ships and cargo. You need excess lift (i.e. more than that required to just hover) in order to slow down. The more excess lift you have, the faster you slow down.

That also means you need to set your descent trigger altitude sufficiently high to give it enough time to slow down. If you don't have much excess lift, this might take awhile, and time = distance/altitude. I haven't tested this extensively, but it looks like the script attempts to slow down far in advance to prevent disaster.

I also recommend having an ascent camera pointing straight up, and a descent camera pointing straight down, to watch out for in-grav asteroids that you might crash into.

If you depend on atmo thrusters for excess lift, it may be late in descent before they kick in.

If you depend on atmo thrusters, use care when descending over mountains, as the atmosphere may not get thick enough for the atmos to kick in fully.

Commands

Command
Argument
Description
<no command>
-
Toggle cruise state
cruise
-
Toggle cruise state
align
on|off
Turn gravity-aligner on or off
align
-
Toggle gravity-aligner state
ts
<number>
Sets target speed (positive ascends; negative descends
cg
yes|no
Disable at zero-G
td
up | down | forward | backward | auto
travel direction (default up; auto will select direction of most thrust)
mx
<altitude in m>
Auto-disengage altitude on ascent
mn
<altitude in m>
Auto-disengage altitude on descent
rf
ground|sea
Altitude reference
ws
<speed in m/s>
World top speed (default 100; change if using speed mods)
ag
yes|no
Disable at zero-G
reset
-
Re-scan for tagged blocks and update saved storage (sit in the Main Cockpit when you run this)
on
-
Enable cruise
off
-
Disable cruise
swap
Toggle between downward or backward thrust



My Rationale For Publishing This
It is debatable whether I should be publishing this, but here's my rationale:
  • Blargmode didn't respond to requests for updates to v1.0 of the script for >2 years
  • Blargmode didn't respond to a comment on V1.0 of the script asking if it was ok to repub an update
  • A redditor indicated that Blargmode was online but unresponsive to queries on Discord
  • Anyone could copy/paste their 2.0-beta code into a PB by Blargmode's invitation, so all I am doing is providing the convenience of doing so via the traditional workshop subscription model.
  • Blargmode didn't make any statement in their published items about republishing

I'm not blaming Blargmode - I just want to convey that I feel like I did my due diligence. There could be any number of valid or unfortunate reasons for Blargmode to unplug. I hope they are ok, and I hope they are ok with this. If Blargmode indicates a problem with this post, I will take it down.




21 Comments
StubieDubie  [author] 30 May @ 9:51pm 
Updated to add UpdateType.Script, fix the 'off' and fix the behaviour when aligner auto-disengage is disabled. It seems to overshoot the target altitude a little now, which I don't remember it doing before. Not sure why that would have changed.
StubieDubie  [author] 28 Apr @ 2:31pm 
Sorry, haven't been playing SE lately. I'll try to look into these shortly.
PimpMyDog 27 Apr @ 5:16pm 
For that there should be on line nr. 694

if ((updateType & (UpdateType.Terminal | UpdateType.Trigger | UpdateType.Script)) != 0)
PimpMyDog 27 Apr @ 4:55pm 
Would it be too much to ask if you could make it listen to script updateType commands? Currently you can only send commands through terminal or button but not from another script.
PimpMyDog 19 Apr @ 10:03pm 
I think there's a bug with the "off" command. It functions the same as the "on" command.
StubieDubie  [author] 14 Feb @ 7:16pm 
You're welcome! But full credit to Blargmode, of course
MrRooma 13 Feb @ 5:29pm 
This is just what I was in need of thank you - works great.
StubieDubie  [author] 28 Dec, 2024 @ 12:41pm 
I'm really not sure why he didn't release v2.
Kaito 28 Dec, 2024 @ 8:26am 
While Blarg seems to have updated his script, it's still v1. I quite prefer v2, so I'm going to keep using this until (if ever) he uploads v2 himself.
[HTK]Trinity99 1 Nov, 2024 @ 11:41am 
This script crashes the server for me. No logs it does not start.