Space Engineers

Space Engineers

112 ratings
Launch Control Script
   
Award
Favorite
Favorited
Unfavorite
File Size
Posted
Updated
13.474 KB
May 26, 2016 @ 8:04am
Dec 23, 2019 @ 4:50am
15 Change Notes ( view )

Subscribe to download
Launch Control Script

Description
This script is used to launch missiles guided by the Easy Lidar Homing Script. It is recommended to use this script for launching said missiles.

Easy Lidar Homing Script can be found at:
http://steamcommunity.com/sharedfiles/filedetails/?id=807454034


How To Use

1) Load the script into a Programmable Block.

2) Configure the script using Custom Data (See screenshots below on how to configure these variables). The 4 configurable parameters are listed below:

strComputerTag
Name tag of the Programmable Block loaded with the Easy Lidar Homing Script (Can also be used with Trajectory Missile Script).

strDetachConnectorTag
(Optional) Name tag of the Connector closest to the Programmable Block to Unlock. This is in case your missile is attached using Merge Block AND Connector. Set blank to disable this feature.

launchSelectionType
(Optional) Launch selection preference. 0 = Any Timer Block, 1 = Closest Timer Block, 2 = Furthest Timer Block.

strAdditionalCustomData
(Optional) Additional Custom Data to be injected to the Programmable Block of the Easy Lidar Homing Script. Use \n for different lines (see below example for reference). This can be used to dynamically set values such as lock on distance, different R_FORWARD to use etc (See Easy Lidar Homing Script's Custom Data Configuration Section for available variables).






Each variable must be specified in the following format, with each one on a new line:

<VARIABLE1>=<VALUE1>
<VARIABLE2>=<VALUE2>
<VARIABLE3>=<VALUE3>


Example:

strComputerTag=TorpedoComputer
launchSelectionType=2
strAdditionalCustomData=useOffsetTargeting=true\nraycastAheadCount=3



3) Trigger this script from your Toolbar as Run or Run with default arguments. DO NOT loop this script. It is meant to be triggered once for each missile launch.

For use with Easy Lidar Homing Script, you will execute this script in your Toolbar with the Run Argument you intended to be set to the missile.
Example: You have 5 toolbar buttons with this script, each with Run Argument as MODE:0, MODE:1, MODE:2, MODE:3, MODE:4 respectively. This allows you to launch the Easy Lidar Homing Script missile as 5 different modes at the click of a button.





Using This With Trajectory Missile Script

You can setup a Remote Launch System when combined with Trajectory Missile Script and Raycast Target Painter.


1) Add this below line to the Custom Data of the Launch Control Script's PB :

listenerId=LAUNCHSITE


2) Build an Antenna and set its Assigned Programmable Block to this Launch Control Script's PB.


3) Using the Raycast Target Painter, raycast a target, then press Button #8. Ensure antenna on the target painter has enough range to reach this script.


Specific Site Selection

On the Target Painter's Send GPS Computer PB, the Argument field is populated with LAUNCHSITE keyword. This keyword is in sync with the listenerId configured on the Launch Control Script PB's Custom Data. Change both these values to configure different sites for launch selection.
Popular Discussions View All (1)
3
Dec 29, 2016 @ 4:42am
Wanted to comment, but the charlimitation has forced me to use this here.
WallE
79 Comments
Wickedcube Feb 28, 2022 @ 4:34am 
I have everything setup and for some reason my missiles will not lock onto targets. no warnings or anything like it. all it does is shoot forward and spin
FuturisticHead Sep 25, 2021 @ 4:22am 
this script not work for me
Agaisten Jan 25, 2021 @ 6:19pm 
Is there a way I can fire all missiles at once with a one second delay per fired missile? I guess a timer block would work but how should i loop it? This mode would be nice for a missile frigate.
Flying Lemming Soup Mar 26, 2020 @ 12:23pm 
I've ALMOST got my missile system working the way I want... but I've got a couple issues. For one, whenever I hit the 'run' command, only one specific missile will fire, and I can't seem to fire any more. If I tell each missile's computer to fire, the missiles fly without a hitch. Right now, I have four missiles and the fire control computer has this setup:

strComputerTag=TorpedoComputer1
strComputerTag=TorpedoComputer2
etc.

I WANT the launch computer to fire one missile with each key press, in a very specific order. Firing the missiles out of order would be... bad. So how do I pull this off?
Flatulent_Moth™ Mar 23, 2020 @ 2:47pm 
It is fixed in the last update
Flatulent_Moth™ Mar 17, 2020 @ 3:41pm 
I would just like to say that after the recent update/patch (I don't know which), the launch script now returns the error

"Caught Exception during execution of script: Object Reference not set to an instance of an object."

This came from two vehicles that both worked before this update. It is also worth mentioning that the missiles still work.
Nyx Jan 26, 2020 @ 1:15pm 
I appear to have fixed it by updating all the scripts (both the launch script and the guidance script) to the latest version by using the copy from workshop option in the programmable block
Nyx Jan 26, 2020 @ 12:28pm 
I'm also receiving assembly not detected. I ensured the launch control script was referring to the correct guidance block, no dice. Attempting to run the missile guidance code manually resulted in the same error.
Dominator1559 Jan 24, 2020 @ 12:02pm 
+1 on the missile problem ( assembly not detected)
Friendly Travel Agent Dec 25, 2019 @ 5:31pm 
So, I just used the launch control script, and something went wrong, and I hope you can help me. My set up for the launch control script, with the mode 2 lidar missiles has worked well in the past (~1-2 months ago), but as of now, whenever I activate the programmable block with the launch script, or if I activate the missile lidar script directly, the programs will read "Assembly not detected, please recompile script." The missile will not detach from the merge blocks, nor make any attempt to move. If you know how to fix this, I would like to know how as well. Thank you so much.