Space Engineers

Space Engineers

52 ratings
SAMv2 vMod - Modified SAM's Autopilot Manager
   
Award
Favorite
Favorited
Unfavorite
File Size
Posted
Updated
563.684 KB
20 Dec, 2019 @ 11:04am
29 Dec, 2020 @ 8:00pm
12 Change Notes ( view )

Subscribe to download
SAMv2 vMod - Modified SAM's Autopilot Manager

Description
This script is an improved version of the auto pilot script made by Sam linked here: https://steamhost.cn/steamcommunity_com/workshop/filedetails/?id=1653875433

Credit should go to the original author of the script in the link posted above. Also, all images and videos are from the original script's workshop page. I will also be aiming to keep this to be backwards compatible with the original SAMv2 script.

Also, please be aware that modded connectors confuses scripts. If you're using one here, the ship might not dock correctly. Also, if you're using the VCZ Airtight Connectors, please refer to the connector tags below.

Please follow Sam's guide on how to set up your ship from the link above. However, for any additions or modifications to this script, please refer to the guide below.

https://steamhost.cn/steamcommunity_com/sharedfiles/filedetails/?id=2204536319

What This Version Can Do Over the Original:
  • More control over how fast your ship goes depending on what it's doing (is it docking, avoiding collisions, heading straight to the destination, etc? You control how fast it goes on each thing.
  • This does not exceed the speed limit by more than a few m/s. (Disclaimer: if the speed limit is decreased, the ship will need time to slow down)
  • Mechanisms to help avoid overshooting and overspeeding as configured by the user.
  • Does not shoot straight up and slowly sink back down when undocking (on planets).
  • More reliably get from point A to point B than the original script (this is not fool proof though)
  • Reach an assigned cruising altitude to more quickly get from point A to B rather than crawling across the terrain (this must be enabled though)
  • LCD displays on cockpits (this was half-implemented in the original version and currently does not work until the bug is fixed, but it works in vMod)
What This Version Cannot Do Over the Original (which I plan to add in in the future when the original author updates his code on Github)
  • Remotely control the ship through another SAM programmable block
  • Wait for batteries to charge, unloading and loading cargo before undocking automatically

Also, when reporting bugs, please post them here so I can better organize what's wrong. https://github.com/sugardose/SpaceEngineers/issues

You're still free to post them here, but it'll be harder for me to collaborate with you about what's wrong.
127 Comments
Spartan 7 Oct, 2022 @ 6:53am 
Returning to SE and i cant remember.... This script was able to dock on a moving large ship ? Or a ship that can change their position at some point ?
stevejc13 28 May, 2022 @ 12:42pm 
False alarm, sorry. I had to add the SAM tag to the remote control and it all started to work. A few tweaks later and I had a cargo drone doing the grunt work. Thanks!
SCBionicle  [author] 18 May, 2022 @ 6:37pm 
@stevejc13, what are you trying to do? Are you trying to record connectors to your bases? Are your connectors assigned with the SAM tag? Also, SAM ADVERTISE will only work on the programmable blocks, not the control seat. SAM ADVERTISE will change the script's operating mode to broadcasting its available connectors over IGC.
stevejc13 15 May, 2022 @ 1:48pm 
The ADD command throws an exception. I've tried it with no parameters and with 1 or two. It's a C# one, object not set o an instance. Is the code downloaded by the game the same as on GitHub? I have a single dock recorded at the connector where I built the ship. I've flown it to another base and connected there. When I found ADD didn't work I added a programmable block, and LCD, then added SAM ADVERTISE to the control seat. No change sadly.
Roberestarkk 26 Sep, 2021 @ 4:19am 
Oh excellent!
I'm not 100% sure it sounds like the same thing as what I'm after though...?

I'm not worried about drones moving when the mothership is moving, I'm worried about the mothership having to leave the drones behind to move.

I've raised a github issue to try to explain further because steam comments are character limited:
https://github.com/sugardose/SpaceEngineers/issues/11
SCBionicle  [author] 25 Sep, 2021 @ 11:45am 
@custard~SPARTA~, the converging speed isn't live updated, you'll need to restart autopilot for the speed to be updated.

@Roberstarkk, in my free time, I've been fiddling with that capability. Things won't dock while the mothership is moving (I can't get the pathing to live update without killing performance), but it can undock while ship is moving, but not accelerating (by the kinematic definition). This change isn't release, I don't know if I'll release it, but I am experimenting with it when I can.
Roberestarkk 21 Sep, 2021 @ 6:42am 
Is there a way to have this version of SAM work in a kind of mothership type capacity?
The problem I'm having is that my big ship needs to dock to stations occasionally, but when I try that, all the little utility drones undock from the big ship because the big ship thinks it's docked to them rather than the other way around.

I've already checked in with the 'original' SAM and it doesn't seem like it's possible with that out of the box, so it's probably not functionality you've replicated here, but you never know!
custard~SPARTA~ 18 Jun, 2021 @ 9:49am 
When adding an option into the Programmable Blocks custom data for example SAM.Converging_speed=(200), the converging speed doesn't appear to change, what may I be doing wrong. Thanks in advance :)
Grayando 10 May, 2021 @ 7:32am 
Is there a way to set it to fly to an Antenna?
dogma 23 Jan, 2021 @ 10:02am 
Feel free to use my code for it.